def __init_ui(self): self._LCTRL_items.set_columns([_('By'), _('When'), _('Description')]) self._BTN_archive_items.Disable() # there's no GetToolTipText() in wx2.8 self.__mail_script_exists, path = gmShellAPI.detect_external_binary(binary = r'gm-mail_doc') if not self.__mail_script_exists: self._BTN_mail_items.Disable() tt = self._BTN_mail_items.GetToolTipText() + '\n\n' + _('<gm-mail_doc(.bat) not found>') self._BTN_mail_items.SetToolTip(tt) self.__fax_script_exists, path = gmShellAPI.detect_external_binary(binary = r'gm-fax_doc') if not self.__fax_script_exists: self._BTN_fax_items.Disable() tt = self._BTN_fax_items.GetToolTipText() + '\n\n' + _('<gm-fax_doc(.bat) not found>') self._BTN_fax_items.SetToolTip(tt) self.__burn_script_exists, path = gmShellAPI.detect_external_binary(binary = r'gm-burn_doc') if not self.__burn_script_exists: self._BTN_burn_items.Disable() tt = self._BTN_burn_items.GetToolTipText() + '\n\n' + _('<gm-burn_doc(.bat) not found>') self._BTN_burn_items.SetToolTip(tt) # make me and listctrl file drop targets dt = gmGuiHelpers.cFileDropTarget(target = self) self.SetDropTarget(dt) dt = gmGuiHelpers.cFileDropTarget(on_drop_callback = self._drop_target_consume_filenames) self._LCTRL_items.SetDropTarget(dt)
def __init__(self, *args, **kwargs): wxgDataMiningPnl.wxgDataMiningPnl.__init__(self, *args, **kwargs) self.__init_ui() # make me a file drop target dt = gmGuiHelpers.cFileDropTarget(target=self) self.SetDropTarget(dt)
def __init__(self, *args, **kwargs): wxgDataMiningPnl.wxgDataMiningPnl.__init__(self, *args, **kwargs) self.__init_ui() # make me a file drop target dt = gmGuiHelpers.cFileDropTarget(target = self) self.SetDropTarget(dt)
def __init_ui(self): self._LCTRL_items.set_columns([_('By'), _('When'), _('Description')]) self._BTN_archive_items.Disable() # there's no GetToolTipString() in wx2.8 self.__mail_script_exists, path = gmShellAPI.detect_external_binary( binary=r'gm-mail_doc') if not self.__mail_script_exists: self._BTN_mail_items.Disable() try: tt = self._BTN_mail_items.GetToolTipString() + u'\n\n' + _( '<gm-mail_doc(.bat) not found>') except AttributeError: tt = _('<gm-mail_doc(.bat) not found>') self._BTN_mail_items.SetToolTipString(tt) self.__fax_script_exists, path = gmShellAPI.detect_external_binary( binary=r'gm-fax_doc') if not self.__fax_script_exists: self._BTN_fax_items.Disable() try: tt = self._BTN_fax_items.GetToolTipString() + u'\n\n' + _( '<gm-fax_doc(.bat) not found>') except AttributeError: tt = _('<gm-fax_doc(.bat) not found>') self._BTN_fax_items.SetToolTipString(tt) self.__burn_script_exists, path = gmShellAPI.detect_external_binary( binary=r'gm-burn_doc') if not self.__burn_script_exists: self._BTN_burn_items.Disable() try: tt = self._BTN_burn_items.GetToolTipString() + u'\n\n' + _( '<gm-burn_doc(.bat) not found>') except AttributeError: tt = _('<gm-burn_doc(.bat) not found>') self._BTN_burn_items.SetToolTipString(tt) # make me and listctrl a file drop target dt = gmGuiHelpers.cFileDropTarget(self) self.SetDropTarget(dt) dt = gmGuiHelpers.cFileDropTarget(self._LCTRL_items) self._LCTRL_items.SetDropTarget(dt) self._LCTRL_items.add_filenames = self.add_filenames_to_listctrl