]> git.saurik.com Git - wxWidgets.git/commitdiff
Some more demo tweaks
authorRobin Dunn <robin@alldunn.com>
Tue, 24 Feb 2004 02:01:04 +0000 (02:01 +0000)
committerRobin Dunn <robin@alldunn.com>
Tue, 24 Feb 2004 02:01:04 +0000 (02:01 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@25935 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

wxPython/demo/Button.py
wxPython/demo/ContextHelp.py
wxPython/demo/FloatBar.py
wxPython/demo/ListBox.py
wxPython/demo/Main.py
wxPython/demo/ProgressDialog.py

index 628d0936e7e6109d3d7247b15895d8f4be99677a..75e589378503a618ddcdfe886da8a29a2dd11f4f 100644 (file)
@@ -38,13 +38,13 @@ class TestPanel(wx.Panel):
             mask = wx.MaskColour(bmp, wx.BLUE)
 
         bmp.SetMask(mask)
-        b = wx.BitmapButton(self, 30, bmp, (160, 20),
+        b = wx.BitmapButton(self, 30, bmp, (260, 20),
                        (bmp.GetWidth()+10, bmp.GetHeight()+10))
         b.SetToolTipString("This is a bitmap button.")
         self.Bind(wx.EVT_BUTTON, self.OnClick, b)
         
 
-        b = wx.Button(self, 40, "Flat Button", (20,150), style=wx.NO_BORDER)
+        b = wx.Button(self, 40, "Flat Button?", (20,150), style=wx.NO_BORDER)
         b.SetToolTipString("This button has a style flag of wx.NO_BORDER")
         self.Bind(wx.EVT_BUTTON, self.OnClick, b)
 
index 3a6727c504d80932505815e1e3ecf02dd29c4e4d..526a884c83394871833c3c3b9a097dcd927ea1ae 100644 (file)
@@ -89,8 +89,17 @@ class TestPanel(wx.Panel):
 #----------------------------------------------------------------------
 
 def runTest(frame, nb, log):
-    win = TestPanel(nb, log)
-    return win
+    if wx.Platform == "__WXMAC__":
+        dlg = wx.MessageDialog(
+                frame, 'The ContextHelp sample does not currently work well on this platform.',
+                'Sorry', wx.OK | wx.ICON_INFORMATION
+                )
+        dlg.ShowModal()
+        dlg.Destroy()
+        
+    else:
+        win = TestPanel(nb, log)
+        return win
 
 
 #----------------------------------------------------------------------
index 0130f3be0ea0cf4351fa324225d76985a764f02f..6b75e9dbee0fad49db35f9bf671c69c82bc7e0e3 100644 (file)
@@ -81,9 +81,17 @@ class TestFloatBar(wx.Frame):
 #---------------------------------------------------------------------------
 
 def runTest(frame, nb, log):
-    win = TestFloatBar(frame, log)
-    frame.otherWin = win
-    win.Show(True)
+    if wx.Platform == "__WXMAC__":
+        dlg = wx.MessageDialog(
+                frame, 'FloatBar does not work well on this platform.',
+                'Sorry', wx.OK | wx.ICON_INFORMATION
+                )
+        dlg.ShowModal()
+        dlg.Destroy()
+    else:
+        win = TestFloatBar(frame, log)
+        frame.otherWin = win
+        win.Show(True)
 
 #---------------------------------------------------------------------------
 
index 83840b1238c3e1760c75a0b93a369e44c525ee75..ede7ce13b1b8f40c13020533e1eac3ad72276309 100644 (file)
@@ -86,7 +86,7 @@ class TestListBox(wx.Panel):
 
 
         wx.StaticText(self, -1, "Select many:", (200, 50), (65, 18))
-        self.lb2 = wx.ListBox(self, 70, (280, 50), (80, 120), sampleList, wx.LB_EXTENDED)
+        self.lb2 = wx.ListBox(self, 70, (300, 50), (80, 120), sampleList, wx.LB_EXTENDED)
         self.Bind(wx.EVT_LISTBOX, self.EvtMultiListBox, self.lb2)
         self.lb2.Bind(wx.EVT_RIGHT_UP, self.EvtRightButton)
         self.lb2.SetSelection(0)
index 18078861843573c3cfa18e809e27a7e5f714a1d6..76377ae3c1b98d766102f58f0a8f628610b5bd27 100644 (file)
@@ -930,7 +930,7 @@ def main():
         os.chdir(demoPath)
     except:
         pass
-    app = MyApp(0) #wx.Platform == "__WXMAC__")
+    app = MyApp(wx.Platform == "__WXMAC__")
     app.MainLoop()
 
 
index 91441759769016a9be460d310b6891a4fc7ff4dd..ce4220191ba4636388e3cd50cfe05768de34f5e6 100644 (file)
@@ -41,18 +41,19 @@ def runTest(frame, nb, log):
 
 
 overview = """\
+<html><body>
 This class represents a dialog that shows a short message and a progress bar. 
 Optionally, it can display an ABORT button
-
+<p>
 This dialog indicates the progress of some event that takes a while to accomplish, 
 usually, such as file copy progress, download progress, and so on. The display
 is <b>completely</b> under control of the program; you must update the dialog from
 within the program creating it. 
-
+<p>
 When the dialog closes, you must check to see if the user aborted the process or
 not, and act accordingly -- that is, if the PD_CAN_ABORT style flag is set. 
 If not then you may progress blissfully onward.
-
+</body></html>
 """
 
 if __name__ == '__main__':