Esempio n. 1
0
def main(argv):
    app = QApplication(argv)
    parser = qymain.createOptionParser()
    options, args = parser.parse_args(argv)
    db.connectDatabase(options.filename)

    dlg = AddTaskDialog()
    dlg.setWindowFlags(dlg.windowFlags() | Qt.WindowStaysOnTopHint)

    description = app.clipboard().text(QClipboard.Selection)
    dlg.setInitialDescription(description)
    return dlg.exec_()
Esempio n. 2
0
def main(argv):
    app = QApplication(argv)
    parser = qymain.createOptionParser()
    options, args = parser.parse_args(argv)
    db.connectDatabase(options.filename)

    dlg = AddTaskDialog()
    dlg.setWindowFlags(dlg.windowFlags() | Qt.WindowStaysOnTopHint)

    description = app.clipboard().text(QClipboard.Selection)
    dlg.setInitialDescription(description)
    return dlg.exec_()
Esempio n. 3
0
 def editTask(self, taskId):
     task = Task.get(taskId)
     dlg = AddTaskDialog(task, self)
     if dlg.exec_() == QDialog.Accepted:
         self.updateViewAndKeepPosition()
Esempio n. 4
0
 def addTask(self):
     dlg = AddTaskDialog(task=None, parent=self)
     if dlg.exec_() == QDialog.Accepted:
         self.updateViewAndKeepPosition()
Esempio n. 5
0
 def editTask(self, taskId):
     task = Task.get(taskId)
     dlg = AddTaskDialog(task, self)
     if dlg.exec_() == QDialog.Accepted:
         self.updateViewAndKeepPosition()
Esempio n. 6
0
 def addTask(self):
     dlg = AddTaskDialog(task=None, parent=self)
     if dlg.exec_() == QDialog.Accepted:
         self.updateViewAndKeepPosition()