Changeset 81:fe57c64efe5e for src/mlx


Ignore:
Timestamp:
04/14/12 09:19:22 (13 years ago)
Author:
István Váradi <ivaradi@…>
Branch:
default
Phase:
public
Message:

Updated the version, and modified the code to not ask for confirmation when restarting after an update

Location:
src/mlx
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • src/mlx/const.py

    r52 r81  
    44
    55# The version of the program
    6 VERSION="0.004"
     6VERSION="0.005"
    77
    88#-------------------------------------------------------------------------------
  • src/mlx/gui/gui.py

    r80 r81  
    309309        """Quit and restart the application."""
    310310        self.toRestart = True
    311         self._quit()
     311        self._quit(force = True)
    312312
    313313    def flushStdIO(self):
     
    419419        self._logView.scroll_mark_onscreen(buffer.get_insert())
    420420
    421     def _quit(self, what = None):
     421    def _quit(self, what = None, force = False):
    422422        """Quit from the application."""
    423         dialog = gtk.MessageDialog(type = MESSAGETYPE_QUESTION,
    424                                    buttons = BUTTONSTYPE_YES_NO,
    425                                    message_format =
    426                                    "Are you sure to quit the logger?")
    427         result = dialog.run()
    428         dialog.hide()
     423        if force:
     424            result=RESPONSETYPE_YES
     425        else:
     426            dialog = gtk.MessageDialog(type = MESSAGETYPE_QUESTION,
     427                                       buttons = BUTTONSTYPE_YES_NO,
     428                                       message_format =
     429                                       "Are you sure to quit the logger?")
     430            result = dialog.run()
     431            dialog.hide()
    429432       
    430433        if result==RESPONSETYPE_YES:
Note: See TracChangeset for help on using the changeset viewer.