예제 #1
0
 def enterPatternCallBack(self, currDir, newDirName=None):
     if None != currDir and newDirName != None:
         sts = False
         if IsValidFileName(newDirName):
             sts,msg = mkdir(os_path.join(currDir, newDirName))
         else:
             msg = _("Invalid name.")
         if sts:
             self.refresh()
         else:
             self.session.open(MessageBox, msg, type = MessageBox.TYPE_INFO, timeout=5)
예제 #2
0
 def enterPatternCallBack(self, newDirName=None):
     if None != self.currDir and newDirName != None:
         sts = False
         if IsValidFileName(newDirName):
             try: sts,msg = mkdir(os_path.join(self.currDir, newDirName))
             except Exception: sts,msg = False, _("Exception occurs")
         else:
             msg = _("Invalid name.")
         if sts:
             self.requestRefresh()
         else:
             self.session.open(MessageBox, msg, type = MessageBox.TYPE_INFO, timeout=5)
예제 #3
0
 def enterPatternCallBack(self, currDir, newDirName=None):
     if None != currDir and newDirName != None:
         sts = False
         if IsValidFileName(newDirName):
             sts, msg = mkdir(os_path.join(currDir, newDirName))
         else:
             msg = _("Invalid name.")
         if sts:
             self.refresh()
         else:
             self.session.open(MessageBox,
                               msg,
                               type=MessageBox.TYPE_INFO,
                               timeout=5)