Added open and save status messages to the status bar.
This commit is contained in:
@@ -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
|
||||
|
||||
##
|
||||
|
||||
Reference in New Issue
Block a user