Author: bugman
Date: Mon Nov 14 21:22:01 2016
New Revision: 28275

URL: http://svn.gna.org/viewcvs/relax?rev=28275&view=rev
Log:
Removal of the Mac OS X taskbar icon functionality.

This code has been disabled since its deletion back in Jun 2012 (r16772), as it 
does not work with
wxPython 2.8 or 2.9.  However with wxPython Phoenix, the disabled code fails as 
there is no
wx.TaskBarIcon.

Modified:
    trunk/gui/icons.py
    trunk/gui/relax_gui.py

Modified: trunk/gui/icons.py
URL: 
http://svn.gna.org/viewcvs/relax/trunk/gui/icons.py?rev=28275&r1=28274&r2=28275&view=diff
==============================================================================
--- trunk/gui/icons.py  (original)
+++ trunk/gui/icons.py  Mon Nov 14 21:22:01 2016
@@ -42,84 +42,5 @@
             self.AddIconFromFile(status.install_path + sep + 'graphics' + sep 
+ 'ulysses.ico', wx.BITMAP_TYPE_ANY)
 
 
-class Relax_task_bar_icon(wx.TaskBarIcon):
-    """The icon for the Mac OS X task bar."""
-
-    # Set up some ID numbers for the menu entries.
-    TBMENU_RESTORE = wx.NewId()
-    TBMENU_CLOSE   = wx.NewId()
-
-    def __init__(self, gui):
-        """Set up the task bar icon.
-
-        @param gui:     The GUI object.
-        @type gui:      wx.Frame instance
-        """
-
-        # Store the args.
-        self.gui = gui
-
-        # Initilise the base class.
-        wx.TaskBarIcon.__init__(self)
-
-        # Set the task bar icon.
-        self.SetIcon(wx.Icon(status.install_path + sep + 'graphics' + sep + 
'ulysses_shadowless_trans_128x128.png', wx.BITMAP_TYPE_ANY))
-
-        # Bind mouse events.
-        self.Bind(wx.EVT_TASKBAR_LEFT_DCLICK, self.restore)
-
-
-    def CreatePopupMenu(self):
-        """Create and return the task bar menu.
-
-        @return:    The pop up menu.
-        @rtype:     wx.Menu instance
-        """
-
-        # Initialise the menu.
-        popup = wx.Menu()
-
-        # Add some menu entries.
-        popup.Append(self.TBMENU_RESTORE, "Restore relax")
-        popup.Append(self.TBMENU_CLOSE,   "Exit relax")
-
-        # Bind the menu events.
-        self.Bind(wx.EVT_MENU, self.restore, id=self.TBMENU_RESTORE)
-        self.Bind(wx.EVT_MENU, self.exit, id=self.TBMENU_CLOSE)
-
-        # Return the menu.
-        return popup
-
-
-    def exit(self, event):
-        """Exit relax from the task bar.
-
-        @param event:   The wx event.
-        @type event:    wx event
-        """
-
-        # Exit relax.
-        wx.CallAfter(self.gui.exit_gui)
-
-
-    def restore(self, event):
-        """Restore relax from the task bar.
-
-        @param event:   The wx event.
-        @type event:    wx event
-        """
-
-        # Show relax.
-        if status.show_gui and not self.gui.IsShown():
-            self.gui.Show(True)
-
-        # De-iconise relax.
-        if self.gui.IsIconized():
-            self.gui.Iconize(False)
-
-        # Raise relax to the top of the window hierarchy.
-        self.gui.Raise()
-
-
 # Set up the main set of icons for relax.
 relax_icons = Relax_icons()

Modified: trunk/gui/relax_gui.py
URL: 
http://svn.gna.org/viewcvs/relax/trunk/gui/relax_gui.py?rev=28275&r1=28274&r2=28275&view=diff
==============================================================================
--- trunk/gui/relax_gui.py      (original)
+++ trunk/gui/relax_gui.py      Mon Nov 14 21:22:01 2016
@@ -131,10 +131,6 @@
         relax_icons.setup()
         self.SetIcons(relax_icons)
 
-        # Set up the Mac OS X task bar icon.
-        #if status.wx_info["os"] == 'darwin' and status.wx_info["build"] != 
'gtk':
-        #    self.taskbar_icon = Relax_task_bar_icon(self)
-
         # Initialise some variables for the GUI.
         self.launch_dir = getcwd()
 


_______________________________________________
relax (http://www.nmr-relax.com)

This is the relax-commits mailing list
relax-commits@gna.org

To unsubscribe from this list, get a password
reminder, or change your subscription options,
visit the list information page at
https://mail.gna.org/listinfo/relax-commits

Reply via email to