mailr26301 - in /branches/space_mapping_refactor: ./ gui/controller.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on October 16, 2014 - 18:20:
Author: bugman
Date: Thu Oct 16 18:20:07 2014
New Revision: 26301

URL: http://svn.gna.org/viewcvs/relax?rev=26301&view=rev
Log:
Merged revisions 26291-26292 via svnmerge from 
svn+ssh://bugman@xxxxxxxxxxx/svn/relax/trunk

........
  r26291 | bugman | 2014-10-15 17:57:52 +0200 (Wed, 15 Oct 2014) | 9 lines
  
  Fix for the find next bug in the relax controller window.
  
  This is bug #22815 (https://gna.org/bugs/?22815), the failure of find next 
using F3 (or Ctrl-G on
  Mac OS X) in the relax controller window if search text has already been 
set.
  
  The fix was simple, as the required flags are in the self.find_data class 
object (an instance of
  wx.FindReplaceData).
........
  r26292 | bugman | 2014-10-15 18:23:29 +0200 (Wed, 15 Oct 2014) | 9 lines
  
  Fix for find dialog in the relax controller window.
  
  This is for bug #22816 (https://gna.org/bugs/?22816), the find 
functionality of the relax controller
  window does not find text when using wxPython >= 2.9.
  
  The find wxPython events are now bound to the find dialog rather than the 
relax controller window
  LogCtrl element for displaying the relax messages.  This works on all 
wxPython versions.
........

Modified:
    branches/space_mapping_refactor/   (props changed)
    branches/space_mapping_refactor/gui/controller.py

Propchange: branches/space_mapping_refactor/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Thu Oct 16 18:20:07 2014
@@ -1 +1 @@
-/trunk:1-26279,26283-26290
+/trunk:1-26279,26283-26292

Modified: branches/space_mapping_refactor/gui/controller.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/space_mapping_refactor/gui/controller.py?rev=26301&r1=26300&r2=26301&view=diff
==============================================================================
--- branches/space_mapping_refactor/gui/controller.py   (original)
+++ branches/space_mapping_refactor/gui/controller.py   Thu Oct 16 18:20:07 
2014
@@ -651,9 +651,6 @@
         self.orig_zoom = self.GetZoom()
 
         # Bind events.
-        self.Bind(wx.EVT_FIND, self.find)
-        self.Bind(wx.EVT_FIND_NEXT, self.find)
-        self.Bind(wx.EVT_FIND_CLOSE, self.find_close)
         self.Bind(wx.EVT_KEY_DOWN, self.capture_keys)
         self.Bind(wx.EVT_MOUSE_EVENTS, self.capture_mouse)
         self.Bind(wx.EVT_MOUSEWHEEL, self.capture_mouse_wheel)
@@ -795,7 +792,7 @@
         sel = self.find_data.GetFindString()
 
         # The search flags.
-        flags = event.GetFlags()
+        flags = self.find_data.GetFlags()
 
         # Shift the search anchor 1 character forwards (if not at the end) 
to ensure the next instance is found.
         pos = self.GetCurrentPos()
@@ -865,7 +862,15 @@
 
         # Initialise the dialog if it doesn't exist.
         if self.find_dlg == None:
+            # Initalise.
             self.find_dlg = wx.FindReplaceDialog(self, self.find_data, 
"Find")
+
+            # Bind the find events to this dialog.
+            self.find_dlg.Bind(wx.EVT_FIND, self.find)
+            self.find_dlg.Bind(wx.EVT_FIND_NEXT, self.find)
+            self.find_dlg.Bind(wx.EVT_FIND_CLOSE, self.find_close)
+
+            # Show the dialog.
             if status.show_gui:
                 self.find_dlg.Show(True)
 




Related Messages


Powered by MHonArc, Updated Thu Oct 16 18:40:02 2014