Changeset 1d4e2e7 in sasview


Ignore:
Timestamp:
Apr 5, 2014 8:20:09 AM (10 years ago)
Author:
Mathieu Doucet <doucetm@…>
Branches:
master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
7e44299
Parents:
30fbe6d
Message:

change useless button to color swatch

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sans/guiframe/gui_statusbar.py

    r30fbe6d r1d4e2e7  
    133133        # Create status bar icon reflecting the type of status 
    134134        # for the last message 
    135         self.bitmap_bt_warning = wx.Button(self, wx.NewId(), "",  
    136                                  size=(width, height), style=wx.NO_BORDER) 
    137         self.bitmap_bt_warning.SetBackgroundColour(GREEN) 
    138         self.bitmap_bt_warning.SetForegroundColour(GREEN) 
     135        self.status_color = wx.StaticText(self, id=wx.NewId(), label="   ") 
     136        self.status_color.SetBackgroundColour(GREEN) 
    139137 
    140138        # Create the button used to show the console dialog 
     
    187185        self.gauge.SetPosition((rect.x, rect.y)) 
    188186        rect = self.GetFieldRect(ICON_POSITION) 
    189         self.bitmap_bt_warning.SetPosition((rect.x, rect.y)) 
     187        self.status_color.SetPosition((rect.x, rect.y)) 
    190188        rect = self.GetFieldRect(CONSOLE_POSITION) 
    191189        self.console_button.SetPosition((rect.x, rect.y)) 
     
    214212        wxStatusB.SetStatusText(self, text, number) 
    215213        self.list_msg.append(text) 
    216         self.bitmap_bt_warning.SetBackgroundColour(GREEN) 
    217         self.bitmap_bt_warning.SetForegroundColour(GREEN) 
     214        self.status_color.SetBackgroundColour(GREEN) 
    218215 
    219216        if self.frame is not None : 
     
    298295        msg = event.info.lower() 
    299296        if msg == "warning": 
    300             self.bitmap_bt_warning.SetBackgroundColour(YELLOW) 
    301             self.bitmap_bt_warning.SetForegroundColour(YELLOW) 
     297            self.status_color.SetBackgroundColour(YELLOW) 
    302298        elif msg == "error": 
    303             self.bitmap_bt_warning.SetBackgroundColour(RED) 
    304             self.bitmap_bt_warning.SetForegroundColour(RED) 
     299            self.status_color.SetBackgroundColour(RED) 
    305300        else: 
    306             self.bitmap_bt_warning.SetBackgroundColour(GREEN) 
    307             self.bitmap_bt_warning.SetForegroundColour(GREEN) 
     301            self.status_color.SetBackgroundColour(GREEN) 
    308302     
    309303    def set_dialog(self, event): 
Note: See TracChangeset for help on using the changeset viewer.