def setUp(self): qtlib.initfontcache(self.repo.ui) self.widget = repofilter.RepoFilterBar(self.repo) self.branchchanged = mock.Mock() self.widget.branchChanged.connect(self.branchchanged) # without show(), action.setChecked() sometimes fails with # "illegal hardware instruction" self.widget.show()
def setUp(self): qtlib.initfontcache(self.repo.ui) self.widget = repofilter.RepoFilterBar(self.repo) self.branchchanged = mock.Mock() self.widget.branchChanged.connect(self.branchchanged) # without show(), action.setChecked() sometimes fails with # "illegal hardware instruction" self.widget.show()
def __call__(self, dlgfunc, ui, *args, **opts): portable_fork(ui, opts) if self._mainapp: self._opendialog(dlgfunc, ui, *args, **opts) return QSettings.setDefaultFormat(QSettings.IniFormat) self._mainapp = QApplication(sys.argv) self._gc = GarbageCollector(self, self.debug) try: # default org is used by QSettings self._mainapp.setApplicationName('TortoiseHgQt') self._mainapp.setOrganizationName('TortoiseHg') self._mainapp.setOrganizationDomain('tortoisehg.org') self._mainapp.setApplicationVersion(thgversion.version()) self._installtranslator() qtlib.setup_font_substitutions() qtlib.fix_application_font() qtlib.configstyles(ui) qtlib.initfontcache(ui) self._mainapp.setWindowIcon(qtlib.geticon('thg-logo')) if 'repository' in opts: try: # Ensure we can open the repository before opening any # dialog windows. Since thgrepo instances are cached, this # is not wasted. from tortoisehg.hgqt import thgrepo thgrepo.repository(ui, opts['repository']) except error.RepoError, e: qtlib.WarningMsgBox(_('Repository Error'), hglib.tounicode(str(e))) return dlg = dlgfunc(ui, *args, **opts) if dlg: dlg.show() dlg.raise_()
def __call__(self, dlgfunc, ui, *args, **opts): portable_fork(ui, opts) if self._mainapp: self._opendialog(dlgfunc, ui, *args, **opts) return QSettings.setDefaultFormat(QSettings.IniFormat) self._mainapp = QApplication(sys.argv) self._gc = GarbageCollector(self, self.debug) try: # default org is used by QSettings self._mainapp.setApplicationName('TortoiseHgQt') self._mainapp.setOrganizationName('TortoiseHg') self._mainapp.setOrganizationDomain('tortoisehg.org') self._mainapp.setApplicationVersion(thgversion.version()) self._installtranslator() qtlib.setup_font_substitutions() qtlib.fix_application_font() qtlib.configstyles(ui) qtlib.initfontcache(ui) self._mainapp.setWindowIcon(qtlib.geticon('thg-logo')) if 'repository' in opts: try: # Ensure we can open the repository before opening any # dialog windows. Since thgrepo instances are cached, this # is not wasted. from tortoisehg.hgqt import thgrepo thgrepo.repository(ui, opts['repository']) except error.RepoError, e: qtlib.WarningMsgBox(hglib.tounicode(_('Repository Error')), hglib.tounicode(str(e))) return dlg = dlgfunc(ui, *args, **opts) if dlg: dlg.show() dlg.raise_()
def setUp(self): qtlib.initfontcache(self.repo.ui) self.widget = repofilter.RepoFilterBar(self.repo) # without show(), action.setChecked() sometimes fails with # "illegal hardware instruction" self.widget.show()
def setUp(self): qtlib.initfontcache(self.repo.ui) self.widget = repofilter.RepoFilterBar(self.repo) # without show(), action.setChecked() sometimes fails with # "illegal hardware instruction" self.widget.show()