diff --git a/gui/builtinStatsViews/resistancesViewFull.py b/gui/builtinStatsViews/resistancesViewFull.py index 4d68a12b0..629087ed9 100644 --- a/gui/builtinStatsViews/resistancesViewFull.py +++ b/gui/builtinStatsViews/resistancesViewFull.py @@ -89,7 +89,7 @@ class ResistancesViewFull(StatsView): bitmap.SetToolTip(tooltip) sizerResistances.Add(bitmap, wx.GBPosition( row, col ), wx.GBSpan( 1, 1 ), wx.ALIGN_CENTER) col+=1 - self.stEHPs = wx.StaticText(contentPanel, wx.ID_ANY, "EHP", style = wx.DOUBLE_BORDER) + self.stEHPs = wx.StaticText(contentPanel, wx.ID_ANY, "EHP", style = wx.SIMPLE_BORDER if 'wxGTK' in wx.PlatformInfo else wx.DOUBLE_BORDER) self.stEHPs.SetToolTip(wx.ToolTip("Click to toggle between effective HP and raw HP")) self.stEHPs.Bind(wx.EVT_LEFT_UP, self.toggleEHP) diff --git a/gui/mainFrame.py b/gui/mainFrame.py index 64f78ac75..c85514d32 100644 --- a/gui/mainFrame.py +++ b/gui/mainFrame.py @@ -34,6 +34,7 @@ from gui.preferenceDialog import PreferenceDialog import aboutData import gui.fittingView as fv from wx._core import PyDeadObjectError +import os.path class MainFrame(wx.Frame): __instance = None @@ -183,10 +184,12 @@ class MainFrame(wx.Frame): path = dlg.GetPath() if (format == 0): output = sFit.exportFit(self.getActiveFit()) - path += ".cfg" + if '.' not in os.path.basename(path): + path += ".cfg" elif (format == 1): output = sFit.exportXml(self.getActiveFit()) - path += ".xml" + if '.' not in os.path.basename(path): + path += ".xml" else: print "oops, invalid fit format %d" % format dlg.Destroy() @@ -279,7 +282,9 @@ class MainFrame(wx.Frame): style = wx.FD_SAVE | wx.FD_OVERWRITE_PROMPT) if (saveDialog.ShowModal() == wx.ID_OK): filePath = saveDialog.GetPath() - sFit.backupFits(filePath) + if '.' not in os.path.basename(filePath): + filePath += ".xml" + sFit.backupFits(filePath ) saveDialog.Destroy() def toggleShipBrowser(self, event): diff --git a/gui/shipBrowser.py b/gui/shipBrowser.py index 983e26fea..3c106438d 100644 --- a/gui/shipBrowser.py +++ b/gui/shipBrowser.py @@ -305,7 +305,7 @@ class HeaderPane (wx.Panel): self.sbSearch.Bind(wx.EVT_LEFT_UP, self.OnLeftUp) self.Layout() -# self.spanel.Hide() + self.spanel.Hide() self.search.Hide() def OnLeftDown(self, event): @@ -318,7 +318,7 @@ class HeaderPane (wx.Panel): def scheduleSearch(self, event): if self.inPopup: - return + return search = self.search.GetValue() if len(search) < 3 and len(search) >0: if self.inSearch == True: @@ -383,6 +383,7 @@ class HeaderPane (wx.Panel): return if self.toggleSearch == 1: self.search.Show(False) + self.spanel.Show(False) self.toggleSearch = -1 # if self.menu: @@ -400,6 +401,7 @@ class HeaderPane (wx.Panel): def editCheckEsc(self, event): if event.GetKeyCode() == wx.WXK_ESCAPE: self.search.Show(False) + self.spanel.Show(False) self.toggleSearch = -1 else: event.Skip() @@ -508,6 +510,7 @@ class HeaderPane (wx.Panel): self.toggleSearch = -1 return if not self.search.IsShown(): + self.spanel.Show(True) self.search.Show(True) self.search.SetFocus() self.toggleSearch = 1 @@ -516,6 +519,7 @@ class HeaderPane (wx.Panel): else: self.search.Show(False) + self.spanel.Show(False) self.toggleSearch = -1 self.Layout() event.Skip()