コード例 #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
ファイル: iptvdirbrowser.py プロジェクト: sarada/eePlugins
 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)