Added open and save status messages to the status bar.

This commit is contained in:
Veronica K. B. Olsen
2019-05-04 10:24:40 +02:00
parent e82eadea3e
commit faa1fe6efb
6 changed files with 28 additions and 10 deletions
+6 -2
View File
@@ -46,12 +46,14 @@ class NWDoc():
if path.isfile(docPath):
with open(docPath,mode="r") as inFile:
return inFile.read()
theDoc = inFile.read()
else:
logger.debug("The requested document does not exist.")
return ""
return None
self.theParent.statusBar.setStatus("Opened Document: %s" % self.theItem.itemName)
return theDoc
def saveDocument(self, docText):
@@ -78,6 +80,8 @@ class NWDoc():
if path.isfile(docTemp): unlink(docTemp)
self.theParent.statusBar.setStatus("Saved Document: %s" % self.theItem.itemName)
return True
##