Skip to content

Commit 222ac46

Browse files
committed
Added GoBack and GoForward tests to the wxpython example on Linux.
1 parent d449c93 commit 222ac46

4 files changed

Lines changed: 43 additions & 2 deletions

File tree

cefpython/cef3/linux/binaries_32bit/wxpython.html

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,13 @@ <h3>Popup</h3>
3030

3131

3232

33+
<h3>Create another browser</h3>
34+
<a href="javascript:external.CreateAnotherBrowser()">
35+
external.CreateAnotherBrowser()</a>
36+
37+
38+
39+
3340
<h3>HTML5 video and accelerated content</h3>
3441
<a href="http://www.youtube.com/watch?v=siOHh0uzcuY&html5=True">
3542
HTML 5 video</a><br>
@@ -151,7 +158,6 @@ <h3>Python callbacks</h3>
151158

152159

153160

154-
155161
<h3>Display handler</h3>
156162

157163
<pre>
@@ -222,7 +228,6 @@ <h3>Display handler</h3>
222228

223229

224230

225-
226231
<h3>Keyboard handler</h3>
227232
<p>
228233
Press F5 to reload the page.<br>
@@ -490,5 +495,15 @@ <h3>Load Handler</h3>
490495
</pre>
491496
No test for that yet.
492497

498+
499+
500+
501+
<h3>Other tests</h3>
502+
503+
<ul>
504+
<li><a href="javascript:external.GoBack()">external.GoBack()</a>
505+
<li><a href="javascript:external.GoForward()">external.GoForward()</a>
506+
</ul>
507+
493508
</body>
494509
</html>

cefpython/cef3/linux/binaries_32bit/wxpython.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,16 @@ class JavascriptExternal:
165165
def __init__(self, mainBrowser):
166166
self.mainBrowser = mainBrowser
167167

168+
def GoBack(self):
169+
self.mainBrowser.GoBack()
170+
171+
def GoForward(self):
172+
self.mainBrowser.GoForward()
173+
174+
def CreateAnotherBrowser(self):
175+
frame = MainFrame()
176+
frame.Show()
177+
168178
def Print(self, message):
169179
print(message)
170180

cefpython/cef3/linux/binaries_64bit/wxpython.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -495,5 +495,15 @@ <h3>Load Handler</h3>
495495
</pre>
496496
No test for that yet.
497497

498+
499+
500+
501+
<h3>Other tests</h3>
502+
503+
<ul>
504+
<li><a href="javascript:external.GoBack()">external.GoBack()</a>
505+
<li><a href="javascript:external.GoForward()">external.GoForward()</a>
506+
</ul>
507+
498508
</body>
499509
</html>

cefpython/cef3/linux/binaries_64bit/wxpython.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,12 @@ class JavascriptExternal:
165165
def __init__(self, mainBrowser):
166166
self.mainBrowser = mainBrowser
167167

168+
def GoBack(self):
169+
self.mainBrowser.GoBack()
170+
171+
def GoForward(self):
172+
self.mainBrowser.GoForward()
173+
168174
def CreateAnotherBrowser(self):
169175
frame = MainFrame()
170176
frame.Show()

0 commit comments

Comments
 (0)