Skip to content

Commit 12b5103

Browse files
committed
Fixed compile errors on Linux. Issue 146.
1 parent 028a36b commit 12b5103

4 files changed

Lines changed: 10 additions & 4 deletions

File tree

cefpython/cef3/LOG_DEBUG.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ inline std::string NowTime()
196196
struct timeval tv;
197197
gettimeofday(&tv, 0);
198198
char result[100] = {0};
199-
std::sprintf(result, "%s.%03ld", buffer, (long)tv.tv_usec / 1000);
199+
sprintf(result, "%s.%03ld", buffer, (long)tv.tv_usec / 1000);
200200
return result;
201201
}
202202

cefpython/cef3/linux/setup/cefpython.h

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,17 @@
1313
#endif
1414

1515
__PYX_EXTERN_C DL_IMPORT(void) PyBrowser_ShowDevTools(CefRefPtr<CefBrowser>);
16+
__PYX_EXTERN_C DL_IMPORT(void) PyTaskRunnable(int);
1617
__PYX_EXTERN_C DL_IMPORT(void) V8ContextHandler_OnContextCreated(CefRefPtr<CefBrowser>, CefRefPtr<CefFrame>);
1718
__PYX_EXTERN_C DL_IMPORT(void) V8ContextHandler_OnContextReleased(int, int64);
1819
__PYX_EXTERN_C DL_IMPORT(void) V8FunctionHandler_Execute(CefRefPtr<CefBrowser>, CefRefPtr<CefFrame>, CefString &, CefRefPtr<CefListValue>);
1920
__PYX_EXTERN_C DL_IMPORT(void) RemovePythonCallbacksForFrame(int);
2021
__PYX_EXTERN_C DL_IMPORT(bool) ExecutePythonCallback(CefRefPtr<CefBrowser>, int, CefRefPtr<CefListValue>);
21-
__PYX_EXTERN_C DL_IMPORT(void) LifespanHandler_OnBeforeClose(CefRefPtr<CefBrowser>);
2222
__PYX_EXTERN_C DL_IMPORT(bool) LifespanHandler_OnBeforePopup(CefRefPtr<CefBrowser>, CefRefPtr<CefFrame>, CefString const &, CefString const &, int const , CefWindowInfo &, CefRefPtr<CefClient> &, CefBrowserSettings &, bool *);
23+
__PYX_EXTERN_C DL_IMPORT(void) LifespanHandler_OnAfterCreated(CefRefPtr<CefBrowser>);
24+
__PYX_EXTERN_C DL_IMPORT(bool) LifespanHandler_RunModal(CefRefPtr<CefBrowser>);
25+
__PYX_EXTERN_C DL_IMPORT(bool) LifespanHandler_DoClose(CefRefPtr<CefBrowser>);
26+
__PYX_EXTERN_C DL_IMPORT(void) LifespanHandler_OnBeforeClose(CefRefPtr<CefBrowser>);
2327
__PYX_EXTERN_C DL_IMPORT(void) DisplayHandler_OnAddressChange(CefRefPtr<CefBrowser>, CefRefPtr<CefFrame>, CefString const &);
2428
__PYX_EXTERN_C DL_IMPORT(void) DisplayHandler_OnTitleChange(CefRefPtr<CefBrowser>, CefString const &);
2529
__PYX_EXTERN_C DL_IMPORT(bool) DisplayHandler_OnTooltip(CefRefPtr<CefBrowser>, CefString &);
@@ -75,6 +79,8 @@ __PYX_EXTERN_C DL_IMPORT(void) JavascriptDialogHandler_OnJavascriptDialogClosed(
7579
__PYX_EXTERN_C DL_IMPORT(void) cefpython_GetDebugOptions(bool *, std::string *);
7680
__PYX_EXTERN_C DL_IMPORT(bool) ApplicationSettings_GetBool(char const *);
7781
__PYX_EXTERN_C DL_IMPORT(bool) ApplicationSettings_GetBoolFromDict(char const *, char const *);
82+
__PYX_EXTERN_C DL_IMPORT(std::string) ApplicationSettings_GetString(char const *);
83+
__PYX_EXTERN_C DL_IMPORT(int) CommandLineSwitches_GetInt(char const *);
7884

7985
#endif /* !__PYX_HAVE_API__cefpython_py27 */
8086

cefpython/cef3/subprocess/cefpython_app.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#include "util.h"
1414
#include "include/cef_runnable.h"
1515
#include "DebugLog.h"
16-
#include "LOG_DEBUG"
16+
#include "LOG_DEBUG.h"
1717
#include <vector>
1818
#include <algorithm>
1919
#include "v8utils.h"

cefpython/string_utils.pyx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ cdef py_string CharToPyString(
4545
# g_applicationSettings["string_encoding"],
4646
# errors=BYTES_DECODE_ERRORS))
4747

48-
# cdef cpp_string PyToCppString(py_string pyString):
48+
# cdef cpp_string PyToCppString(py_string pyString) except *:
4949
# cdef cpp_string cppString = pyString
5050
# return cppString
5151

0 commit comments

Comments
 (0)