(self, browser, frame, httpStatusCode)
| 321 | self.navigationBar.AddToHistory(browser.GetMainFrame().GetUrl()) |
| 322 | |
| 323 | def OnLoadEnd(self, browser, frame, httpStatusCode): |
| 324 | if self.navigationBar: |
| 325 | # In CEF 3 the CanGoBack() and CanGoForward() methods |
| 326 | # sometimes do work, sometimes do not, when called from |
| 327 | # the OnLoadStart event. That's why we're calling it again |
| 328 | # here. This is still not perfect as OnLoadEnd() is not |
| 329 | # guaranteed to get called for all types of pages. See the |
| 330 | # cefpython documentation: |
| 331 | # https://code.google.com/p/cefpython/wiki/LoadHandler |
| 332 | # OnDomReady() would be perfect, but is still not implemented. |
| 333 | # Another option is to implement our own browser state |
| 334 | # using the OnLoadStart and OnLoadEnd callbacks. |
| 335 | self.UpdateButtonsState() |
| 336 | |
| 337 | class DefaultClientHandler(object): |
| 338 | def __init__(self, parentCtrl): |
no test coverage detected