Source

thg-qt-mq / cmdui-debug.diff

Full commit
# HG changeset patch
# User Yuya Nishihara <yuya@tcha.org>
# Date 1273582267 -32400
# Node ID 7ebc57243afa2d8e1e415afeceeb467d3806a6f1
# Parent  19b4839759a68d1fc74eff4322831be548714c9a

diff --git a/tortoisehg/hgqt/cmdui.py b/tortoisehg/hgqt/cmdui.py
--- a/tortoisehg/hgqt/cmdui.py
+++ b/tortoisehg/hgqt/cmdui.py
@@ -5,6 +5,11 @@
 # This software may be used and distributed according to the terms of the
 # GNU General Public License version 2, incorporated herein by reference.
 
+# XXX
+import sys, os
+sys.path.insert(0, os.path.join(os.path.dirname(__file__), '..', '..'))
+sys.path.insert(1, os.path.join(os.path.dirname(__file__), '..', '..', '..', 'mercurial'))
+
 from PyQt4.QtCore import Qt, QObject, pyqtSignal
 from PyQt4.QtGui import QDialog, QDialogButtonBox, QLabel, QProgressBar
 from PyQt4.QtGui import QTextBrowser, QHBoxLayout, QGridLayout, QMessageBox
@@ -316,3 +321,11 @@ class Dialog(QDialog):
 
     def command_canceling(self):
         self.cancel_btn.setDisabled(True)
+
+
+if __name__ == '__main__':  # XXX
+    from PyQt4.QtGui import QApplication
+    app = QApplication(sys.argv)
+    w = Dialog(['version'])
+    w.show()
+    app.exec_()