Commit b5b338bcbe7e65dd744ac28f304a773ce7a92674
1 parent
6392b159
Exists in
master
and in
68 other branches
Change title to "InVesalius 3" in close project FIX: #121
Showing
2 changed files
with
11 additions
and
4 deletions
Show diff stats
invesalius/control.py
... | ... | @@ -162,17 +162,20 @@ class Controller(): |
162 | 162 | print "Close without changes" |
163 | 163 | self.CloseProject() |
164 | 164 | ps.Publisher().sendMessage("Enable state project", False) |
165 | + ps.Publisher().sendMessage('Set project name') | |
165 | 166 | elif answer == 1: |
166 | 167 | self.ShowDialogSaveProject() |
167 | 168 | print "Save changes and close" |
168 | 169 | self.CloseProject() |
169 | 170 | ps.Publisher().sendMessage("Enable state project", False) |
171 | + ps.Publisher().sendMessage('Set project name') | |
170 | 172 | elif answer == -1: |
171 | 173 | print "Cancel" |
172 | 174 | else: |
173 | 175 | self.CloseProject() |
174 | 176 | ps.Publisher().sendMessage("Enable state project", False) |
175 | - | |
177 | + ps.Publisher().sendMessage('Set project name') | |
178 | + | |
176 | 179 | ########################### |
177 | 180 | def OnOpenProject(self, pubsub_evt): |
178 | 181 | path = pubsub_evt.data | ... | ... |
invesalius/gui/frame.py
... | ... | @@ -99,10 +99,14 @@ class Frame(wx.Frame): |
99 | 99 | |
100 | 100 | def SetProjectName(self, pubsub_evt): |
101 | 101 | proj_name = pubsub_evt.data |
102 | - if sys.platform != 'darwin': | |
103 | - self.SetTitle("%s - InVesalius 3"%(proj_name)) | |
102 | + | |
103 | + if not(proj_name): | |
104 | + self.SetTitle("InVesalius 3") | |
104 | 105 | else: |
105 | - self.SetTitle("%s"%(proj_name)) | |
106 | + if sys.platform != 'darwin': | |
107 | + self.SetTitle("%s - InVesalius 3"%(proj_name)) | |
108 | + else: | |
109 | + self.SetTitle("%s"%(proj_name)) | |
106 | 110 | |
107 | 111 | def UpdateAui(self, pubsub_evt): |
108 | 112 | self.aui_manager.Update() | ... | ... |