1414def CreateBrowserSync (windowInfo , browserSettings , navigateUrl ):
1515 return Browser ()
1616
17- def ExceptHook (type , value , traceObject ):
18- return None
19-
2017def FormatJavascriptStackTrace (stackTrace ):
2118 return ""
2219
@@ -26,9 +23,6 @@ def GetBrowserByWindowHandle(windowHandle):
2623def GetJavascriptStackTrace (frameLimit = 100 ):
2724 return []
2825
29- def GetRealPath (file = None , encodeUrl = False ):
30- return ""
31-
3226def Initialize (applicationSettings = {}):
3327 return None
3428
@@ -38,7 +32,7 @@ def IsKeyModifier(key, modifiers):
3832def MessageLoop ():
3933 return None
4034
41- def SingleMessageLoop ():
35+ def MessageLoopWork ():
4236 return None
4337
4438def QuitMessageLoop ():
@@ -62,7 +56,7 @@ def Shutdown():
6256 "locale" : "" ,
6357 "locales_dir_path" : "" ,
6458 "log_file" : "" ,
65- "log_severity" : LOGSEVERITY_VERBOSE ,
59+ "log_severity" : LOGSEVERITY_INFO ,
6660 "release_dcheck_enabled" : False ,
6761 "multi_threaded_message_loop" : False ,
6862 "pack_loading_disabled" : False ,
@@ -183,6 +177,12 @@ def GetFrame(self):
183177 def GetFrameNames (self ):
184178 return ["" , "" ]
185179
180+ def GetIdentifier (self ):
181+ return 0
182+
183+ def GetImage (self , paintElementType , width , height ):
184+ return PaintBuffer ()
185+
186186 def GetJavascriptBindings (self ):
187187 return JavascriptBindings ()
188188
@@ -195,6 +195,9 @@ def GetOpenerWindowHandle(self):
195195 def GetOuterWindowHandle (self ):
196196 return 0
197197
198+ def GetSize (self , paintElementType ):
199+ return (0 ,0 ,)
200+
198201 def GetUserData (self , key ):
199202 return None
200203
@@ -219,6 +222,9 @@ def HasDocument(self):
219222 def HidePopup (self ):
220223 return None
221224
225+ def Invalidate (self , dirtyRect ):
226+ return None
227+
222228 def IsFullscreen (self ):
223229 return False
224230
@@ -237,6 +243,24 @@ def Reload(self):
237243 def ReloadIgnoreCache (self ):
238244 return None
239245
246+ def SendKeyEvent (self , keyType , keyInfo , modifiers ):
247+ return None
248+
249+ def SendMouseClickEvent (self , x , y , mouseButtonType , mouseUp , clickCount ):
250+ return None
251+
252+ def SendMouseMoveEvent (self , x , y , mouseLeave ):
253+ return None
254+
255+ def SendMouseWheelEvent (self , x , y , deltaX , deltaY ):
256+ return None
257+
258+ def SendFocusEvent (self , setFocus ):
259+ return None
260+
261+ def SendCaptureLostEvent (self ):
262+ return None
263+
240264 def SetClientCallback (self , name , callback ):
241265 return None
242266
@@ -249,6 +273,9 @@ def SetFocus(self, enable):
249273 def SetJavascriptBindings (self , javascriptBindings ):
250274 return None
251275
276+ def SetSize (self , paintElementType , width , height ):
277+ return None
278+
252279 def SetZoomLevel (self , zoomLevel ):
253280 return None
254281
@@ -371,9 +398,13 @@ def SetHeaderMap(self, headerMap={}):
371398 def SetHeaderMultimap (self , headerMultimap = []):
372399 return None
373400
374- #
375- # JavascriptBindings class.
376- #
401+ class PaintBuffer :
402+
403+ def GetIntPointer (self ):
404+ return 0
405+
406+ def GetString (self , mode = "bgra" , origin = "top-left" ):
407+ return ""
377408
378409class JavascriptBindings :
379410
@@ -395,10 +426,6 @@ def SetObject(self, name, obj):
395426 def SetProperty (self , name , value ):
396427 return None
397428
398- #
399- # JavascriptCallback object.
400- #
401-
402429class JavascriptCallback :
403430
404431 def Call (self , param1 , param2 , param3_etc ):
@@ -407,6 +434,28 @@ def Call(self, param1, param2, param3_etc):
407434 def GetName (self ):
408435 return name
409436
437+ class WindowUtils :
438+
439+ @staticmethod
440+ def OnSetFocus (windowID , msg , wparam , lparam ):
441+ return 0
442+
443+ @staticmethod
444+ def OnSize (windowID , msg , wparam , lparam ):
445+ return 0
446+
447+ @staticmethod
448+ def OnEraseBackground (windowID , msg , wparam , lparam ):
449+ return 0
450+
451+ @staticmethod
452+ def SetTitle (pyBrowser , pyTitle ):
453+ return None
454+
455+ @staticmethod
456+ def SetIcon (pyBrowser , icon = "inherit" ):
457+ return None
458+
410459#
411460# DisplayHandler.
412461#
@@ -726,26 +775,39 @@ def LifespanHandler_OnBeforeClose(browser):
726775def LifespanHandler_RunModal (browser ):
727776 return False
728777
729- # WindowUtils class.
778+ #
779+ # RenderHandler
780+ #
730781
731- class WindowUtils :
782+ PET_VIEW = 0
783+ PET_POPUP = 0
732784
733- @ staticmethod
734- def OnSetFocus ( windowID , msg , wparam , lparam ):
735- return 0
785+ KEYTYPE_KEYUP = 0
786+ KEYTYPE_KEYDOWN = 0
787+ KEYTYPE_CHAR = 0
736788
737- @ staticmethod
738- def OnSize ( windowID , msg , wparam , lparam ):
739- return 0
789+ MOUSEBUTTON_LEFT = 0
790+ MOUSEBUTTON_MIDDLE = 0
791+ MOUSEBUTTON_RIGHT = 0
740792
741- @staticmethod
742- def OnEraseBackground (windowID , msg , wparam , lparam ):
743- return 0
793+ def RenderHandler_GetViewRect (browser , out_rect ):
794+ return False
744795
745- @staticmethod
746- def SetTitle (pyBrowser , pyTitle ):
747- return None
796+ def RenderHandler_GetScreenRect (browser , out_rect ):
797+ return False
748798
749- @staticmethod
750- def SetIcon (pyBrowser , icon = "inherit" ):
751- return None
799+ def RenderHandler_GetScreenPoint (browser , viewX , viewY , out_screenCoordinates ):
800+ return False
801+
802+ def RenderHandler_OnPopupShow (browser , show ):
803+ return None
804+
805+ def RenderHandler_OnPopupSize (browser , rect ):
806+ return None
807+
808+ def RenderHandler_OnPaint (browser , paintElementType , out_dirtyRects ,
809+ paintBuffer ):
810+ return None
811+
812+ def RenderHandler_OnCursorChange (browser , cursor ):
813+ return None
0 commit comments