PyQt4.QtGui.QMainWindow.__init__ (self)
self.setupUi (self)
self.currentfile = None
+ self.ismodified = False
+
+ # when the document is modified
+ def on_document_modified (self):
+ # set the document modified flag
+ self.ismodified = True
+ print "True"
# update a language in the list of languages
def on_update_lang (self):
selitem.setText (2, str (self.canreadwrite.isChecked ()))
selitem.setText (3, str (self.isproficient.isChecked ()))
+ # modified the document
+ self.ismodified = True
+
# selecting a language from the list of languages
def on_select_lang (self):
# set the language fields from the selected item
self.languageslist.takeTopLevelItem (self.languageslist.indexOfTopLevelItem (item))
self.reset_language_fields ()
+ # set the modified flag
+ self.ismodified = True
# add a language to the list of languages known
def on_add_lang (self):
self.languageslist.addTopLevelItem (langitem)
self.reset_language_fields ()
+ # set the modified flag
+ self.ismodified = True
+
# set the language fields from the selected item
def set_language_fields (self):
selitems = self.languageslist.selectedItems ()
selitem.setText (0, self.skillsettitle.text ())
selitem.setText (1, self.skilldescription.toPlainText ())
+ # set the modified flag
+ self.ismodified = True
# selecting a skill from the list event
def on_select_skill (self):
self.skillslist.takeTopLevelItem (self.skillslist.indexOfTopLevelItem (item))
self.reset_skillset_fields ()
+ # set the modified flag
+ self.ismodified = True
# add skill set button is clicked
def on_add_skill (self):
)
self.skillslist.addTopLevelItem (skillitem)
self.reset_skillset_fields ()
+ # set the modified flag
+ self.ismodified = True
# clear the skill set fields
def reset_skillset_fields (self):
selitem.setText (2, leavedatestr)
selitem.setText (3, self.organization.text ())
selitem.setText (4, self.additionalinfo.text ())
+ # set the modified flag
+ self.ismodified = True
# delete professional history button is clicked
def on_delete_profession (self):
for item in selitems:
self.professionlist.takeTopLevelItem (self.professionlist.indexOfTopLevelItem (item))
self.reset_profession_fields ()
+ # set the modified flag
+ self.ismodified = True
# add professional history button is clicked
def on_add_profession (self):
self.professionlist.addTopLevelItem (professionitem)
self.reset_profession_fields ()
+ # set the modified flag
+ self.ismodified = True
# when selection of profession list is changed
def on_select_profession (self):
for item in selitems:
self.educationlist.takeTopLevelItem (self.educationlist.indexOfTopLevelItem (item))
self.reset_education_fields ()
+ # set the modified flag
+ self.ismodified = True
# selection is changed
def on_select_education (self):
selitem.setText (3, self.university.text ())
selitem.setText (4, self.grade.text ())
selitem.setText (5, str (self.percentage.value ()))
+ # set the modified flag
+ self.ismodified = True
# add educational qualification button
def on_add_education (self):
self.educationlist.addTopLevelItem (educationitem)
# clear the fields
self.reset_education_fields ()
+ # set the modified flag
+ self.ismodified = True
# set fields in the education tab from current selected item
def set_education_fields (self):
<slot>on_add_education()</slot>
<hints>
<hint type="sourcelabel">
- <x>534</x>
- <y>198</y>
+ <x>426</x>
+ <y>189</y>
</hint>
<hint type="destinationlabel">
<x>730</x>
<slot>on_delete_education()</slot>
<hints>
<hint type="sourcelabel">
- <x>677</x>
- <y>198</y>
+ <x>658</x>
+ <y>189</y>
</hint>
<hint type="destinationlabel">
<x>728</x>
<slot>on_select_education()</slot>
<hints>
<hint type="sourcelabel">
- <x>281</x>
- <y>290</y>
+ <x>100</x>
+ <y>217</y>
</hint>
<hint type="destinationlabel">
<x>726</x>
<slot>on_update_education()</slot>
<hints>
<hint type="sourcelabel">
- <x>608</x>
- <y>202</y>
+ <x>579</x>
+ <y>189</y>
</hint>
<hint type="destinationlabel">
<x>728</x>
<slot>on_select_education()</slot>
<hints>
<hint type="sourcelabel">
- <x>648</x>
- <y>303</y>
+ <x>100</x>
+ <y>217</y>
</hint>
<hint type="destinationlabel">
<x>729</x>
<slot>on_change_currentemployment()</slot>
<hints>
<hint type="sourcelabel">
- <x>368</x>
- <y>140</y>
+ <x>328</x>
+ <y>136</y>
</hint>
<hint type="destinationlabel">
<x>728</x>
<slot>on_add_profession()</slot>
<hints>
<hint type="sourcelabel">
- <x>391</x>
- <y>222</y>
+ <x>309</x>
+ <y>216</y>
</hint>
<hint type="destinationlabel">
<x>729</x>
<slot>on_select_profession()</slot>
<hints>
<hint type="sourcelabel">
- <x>553</x>
- <y>351</y>
+ <x>99</x>
+ <y>244</y>
</hint>
<hint type="destinationlabel">
<x>727</x>
<slot>on_select_profession()</slot>
<hints>
<hint type="sourcelabel">
- <x>420</x>
- <y>323</y>
+ <x>99</x>
+ <y>244</y>
</hint>
<hint type="destinationlabel">
<x>729</x>
<slot>on_delete_profession()</slot>
<hints>
<hint type="sourcelabel">
- <x>621</x>
- <y>223</y>
+ <x>596</x>
+ <y>216</y>
</hint>
<hint type="destinationlabel">
<x>729</x>
<slot>on_update_profession()</slot>
<hints>
<hint type="sourcelabel">
- <x>510</x>
- <y>230</y>
+ <x>453</x>
+ <y>216</y>
</hint>
<hint type="destinationlabel">
<x>726</x>
<slot>on_add_skill()</slot>
<hints>
<hint type="sourcelabel">
- <x>307</x>
- <y>240</y>
+ <x>207</x>
+ <y>234</y>
</hint>
<hint type="destinationlabel">
<x>730</x>
<slot>on_delete_skill()</slot>
<hints>
<hint type="sourcelabel">
- <x>598</x>
- <y>238</y>
+ <x>566</x>
+ <y>234</y>
</hint>
<hint type="destinationlabel">
<x>728</x>
<slot>on_select_skill()</slot>
<hints>
<hint type="sourcelabel">
- <x>453</x>
- <y>359</y>
+ <x>99</x>
+ <y>261</y>
</hint>
<hint type="destinationlabel">
<x>730</x>
<slot>on_select_skill()</slot>
<hints>
<hint type="sourcelabel">
- <x>602</x>
- <y>331</y>
+ <x>99</x>
+ <y>261</y>
</hint>
<hint type="destinationlabel">
<x>726</x>
<slot>on_update_skill()</slot>
<hints>
<hint type="sourcelabel">
- <x>437</x>
- <y>243</y>
+ <x>386</x>
+ <y>234</y>
</hint>
<hint type="destinationlabel">
<x>728</x>
<slot>on_add_lang()</slot>
<hints>
<hint type="sourcelabel">
- <x>545</x>
- <y>138</y>
+ <x>547</x>
+ <y>155</y>
</hint>
<hint type="destinationlabel">
<x>729</x>
<slot>on_delete_lang()</slot>
<hints>
<hint type="sourcelabel">
- <x>687</x>
- <y>142</y>
+ <x>716</x>
+ <y>155</y>
</hint>
<hint type="destinationlabel">
<x>733</x>
<slot>on_select_lang()</slot>
<hints>
<hint type="sourcelabel">
- <x>554</x>
- <y>224</y>
+ <x>112</x>
+ <y>189</y>
</hint>
<hint type="destinationlabel">
<x>730</x>
<slot>on_select_lang()</slot>
<hints>
<hint type="sourcelabel">
- <x>617</x>
+ <x>112</x>
<y>189</y>
</hint>
<hint type="destinationlabel">
<slot>on_update_lang()</slot>
<hints>
<hint type="sourcelabel">
- <x>605</x>
- <y>140</y>
+ <x>644</x>
+ <y>155</y>
</hint>
<hint type="destinationlabel">
<x>729</x>
</hint>
</hints>
</connection>
+ <connection>
+ <sender>title</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>480</x>
+ <y>41</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>728</x>
+ <y>28</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>nametitle</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>132</x>
+ <y>144</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>3</x>
+ <y>470</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>firstname</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>267</x>
+ <y>145</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>29</x>
+ <y>475</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>lastname</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>479</x>
+ <y>142</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>1</x>
+ <y>452</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>dateofbirth</sender>
+ <signal>dateChanged(QDate)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>223</x>
+ <y>186</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>538</x>
+ <y>23</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>street</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>170</x>
+ <y>265</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>196</x>
+ <y>23</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>countrycode_landline</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>437</x>
+ <y>268</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>88</x>
+ <y>24</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>telephone</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>527</x>
+ <y>264</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>165</x>
+ <y>-2</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>area</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>204</x>
+ <y>305</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>-1</x>
+ <y>50</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>countrycode_mobile</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>409</x>
+ <y>309</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>575</x>
+ <y>51</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>mobilenumber</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>588</x>
+ <y>305</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>0</x>
+ <y>89</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>city</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>93</x>
+ <y>356</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>-3</x>
+ <y>171</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>email</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>372</x>
+ <y>351</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>2</x>
+ <y>203</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>areacode</sender>
+ <signal>textChanged(QString)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>118</x>
+ <y>396</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>0</x>
+ <y>273</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>married</sender>
+ <signal>toggled(bool)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>149</x>
+ <y>436</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>1</x>
+ <y>327</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>single</sender>
+ <signal>toggled(bool)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>212</x>
+ <y>431</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>3</x>
+ <y>237</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>unspecified</sender>
+ <signal>toggled(bool)</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>303</x>
+ <y>436</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>-2</x>
+ <y>137</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>shorttermcareer</sender>
+ <signal>textChanged()</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>98</x>
+ <y>177</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>0</x>
+ <y>120</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>longtermgoals</sender>
+ <signal>textChanged()</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>82</x>
+ <y>350</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>2</x>
+ <y>443</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>additionalinformation</sender>
+ <signal>textChanged()</signal>
+ <receiver>biacv_mainwindow</receiver>
+ <slot>on_document_modified()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>86</x>
+ <y>375</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>1</x>
+ <y>377</y>
+ </hint>
+ </hints>
+ </connection>
</connections>
<slots>
<slot>on_add_education()</slot>
<slot>on_delete_lang()</slot>
<slot>on_select_lang()</slot>
<slot>on_update_lang()</slot>
+ <slot>on_document_modified()</slot>
</slots>
</ui>
# Form implementation generated from reading ui file 'biacv_mainwindow.ui'
#
-# Created: Fri Dec 2 10:52:04 2011
+# Created: Sun Dec 4 14:23:51 2011
# by: PyQt4 UI code generator 4.8.6
#
# WARNING! All changes made in this file will be lost!
QtCore.QObject.connect(self.languageslist, QtCore.SIGNAL(_fromUtf8("activated(QModelIndex)")), biacv_mainwindow.on_select_lang)
QtCore.QObject.connect(self.languageslist, QtCore.SIGNAL(_fromUtf8("itemSelectionChanged()")), biacv_mainwindow.on_select_lang)
QtCore.QObject.connect(self.updatelanguage, QtCore.SIGNAL(_fromUtf8("clicked()")), biacv_mainwindow.on_update_lang)
+ QtCore.QObject.connect(self.title, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.nametitle, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.firstname, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.lastname, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.dateofbirth, QtCore.SIGNAL(_fromUtf8("dateChanged(QDate)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.street, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.countrycode_landline, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.telephone, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.area, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.countrycode_mobile, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.mobilenumber, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.city, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.email, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.areacode, QtCore.SIGNAL(_fromUtf8("textChanged(QString)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.married, QtCore.SIGNAL(_fromUtf8("toggled(bool)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.single, QtCore.SIGNAL(_fromUtf8("toggled(bool)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.unspecified, QtCore.SIGNAL(_fromUtf8("toggled(bool)")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.shorttermcareer, QtCore.SIGNAL(_fromUtf8("textChanged()")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.longtermgoals, QtCore.SIGNAL(_fromUtf8("textChanged()")), biacv_mainwindow.on_document_modified)
+ QtCore.QObject.connect(self.additionalinformation, QtCore.SIGNAL(_fromUtf8("textChanged()")), biacv_mainwindow.on_document_modified)
QtCore.QMetaObject.connectSlotsByName(biacv_mainwindow)
def retranslateUi(self, biacv_mainwindow):