tryton 7.4.7__tar.gz → 7.6.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of tryton might be problematic. Click here for more details.

Files changed (305) hide show
  1. {tryton-7.4.7 → tryton-7.6.0}/CHANGELOG +7 -32
  2. {tryton-7.4.7 → tryton-7.6.0}/COPYRIGHT +2 -2
  3. {tryton-7.4.7 → tryton-7.6.0}/PKG-INFO +8 -7
  4. {tryton-7.4.7 → tryton-7.6.0}/doc/conf.py +6 -0
  5. {tryton-7.4.7 → tryton-7.6.0}/setup.cfg +1 -1
  6. {tryton-7.4.7 → tryton-7.6.0}/setup.py +4 -4
  7. {tryton-7.4.7 → tryton-7.6.0}/tox.ini +1 -1
  8. {tryton-7.4.7 → tryton-7.6.0}/tryton/__init__.py +1 -1
  9. tryton-7.6.0/tryton/bus.py +143 -0
  10. tryton-7.6.0/tryton/chat.py +179 -0
  11. {tryton-7.4.7 → tryton-7.6.0}/tryton/client.py +7 -0
  12. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/__init__.py +15 -11
  13. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/button.py +1 -1
  14. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/cellrendererfloat.py +1 -1
  15. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/cellrenderertext.py +2 -2
  16. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/common.py +91 -19
  17. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/domain_parser.py +8 -6
  18. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/environment.py +2 -2
  19. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/number_entry.py +12 -6
  20. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/selection.py +1 -1
  21. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/bg/LC_MESSAGES/tryton.mo +0 -0
  22. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/bg/LC_MESSAGES/tryton.po +26 -16
  23. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/ca/LC_MESSAGES/tryton.mo +0 -0
  24. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/ca/LC_MESSAGES/tryton.po +29 -18
  25. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/cs/LC_MESSAGES/tryton.mo +0 -0
  26. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/cs/LC_MESSAGES/tryton.po +28 -16
  27. tryton-7.6.0/tryton/data/locale/de/LC_MESSAGES/tryton.mo +0 -0
  28. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/de/LC_MESSAGES/tryton.po +27 -18
  29. tryton-7.6.0/tryton/data/locale/es/LC_MESSAGES/tryton.mo +0 -0
  30. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/es/LC_MESSAGES/tryton.po +25 -16
  31. tryton-7.6.0/tryton/data/locale/es_419/LC_MESSAGES/tryton.mo +0 -0
  32. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/es_419/LC_MESSAGES/tryton.po +26 -16
  33. tryton-7.6.0/tryton/data/locale/et/LC_MESSAGES/tryton.mo +0 -0
  34. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/et/LC_MESSAGES/tryton.po +28 -18
  35. tryton-7.6.0/tryton/data/locale/fa/LC_MESSAGES/tryton.mo +0 -0
  36. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/fa/LC_MESSAGES/tryton.po +28 -18
  37. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/fi/LC_MESSAGES/tryton.mo +0 -0
  38. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/fi/LC_MESSAGES/tryton.po +25 -16
  39. tryton-7.6.0/tryton/data/locale/fr/LC_MESSAGES/tryton.mo +0 -0
  40. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/fr/LC_MESSAGES/tryton.po +25 -16
  41. tryton-7.6.0/tryton/data/locale/hu/LC_MESSAGES/tryton.mo +0 -0
  42. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/hu/LC_MESSAGES/tryton.po +28 -18
  43. tryton-7.6.0/tryton/data/locale/id/LC_MESSAGES/tryton.mo +0 -0
  44. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/id/LC_MESSAGES/tryton.po +23 -16
  45. tryton-7.6.0/tryton/data/locale/it/LC_MESSAGES/tryton.mo +0 -0
  46. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/it/LC_MESSAGES/tryton.po +29 -18
  47. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/ja_JP/LC_MESSAGES/tryton.mo +0 -0
  48. tryton-7.6.0/tryton/data/locale/lo/LC_MESSAGES/tryton.mo +0 -0
  49. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/lo/LC_MESSAGES/tryton.po +26 -18
  50. tryton-7.6.0/tryton/data/locale/lt/LC_MESSAGES/tryton.mo +0 -0
  51. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/lt/LC_MESSAGES/tryton.po +30 -18
  52. tryton-7.6.0/tryton/data/locale/nl/LC_MESSAGES/tryton.mo +0 -0
  53. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/nl/LC_MESSAGES/tryton.po +25 -16
  54. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/pl/LC_MESSAGES/tryton.mo +0 -0
  55. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/pl/LC_MESSAGES/tryton.po +31 -18
  56. tryton-7.6.0/tryton/data/locale/pt/LC_MESSAGES/tryton.mo +0 -0
  57. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/pt/LC_MESSAGES/tryton.po +148 -177
  58. tryton-7.6.0/tryton/data/locale/ro/LC_MESSAGES/tryton.mo +0 -0
  59. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/ro/LC_MESSAGES/tryton.po +32 -19
  60. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/ru/LC_MESSAGES/tryton.mo +0 -0
  61. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/ru/LC_MESSAGES/tryton.po +28 -16
  62. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/sl/LC_MESSAGES/tryton.mo +0 -0
  63. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/sl/LC_MESSAGES/tryton.po +33 -18
  64. tryton-7.6.0/tryton/data/locale/tr/LC_MESSAGES/tryton.mo +0 -0
  65. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/tr/LC_MESSAGES/tryton.po +25 -16
  66. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/tryton.pot +25 -16
  67. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/uk/LC_MESSAGES/tryton.mo +0 -0
  68. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/uk/LC_MESSAGES/tryton.po +31 -18
  69. tryton-7.6.0/tryton/data/locale/zh_CN/LC_MESSAGES/tryton.mo +0 -0
  70. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/zh_CN/LC_MESSAGES/tryton.po +27 -18
  71. tryton-7.6.0/tryton/data/pixmaps/tryton/tryton-chat.svg +1 -0
  72. tryton-7.6.0/tryton/data/pixmaps/tryton/tryton-note.svg +1 -0
  73. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/attachment.py +2 -2
  74. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/board.py +1 -1
  75. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/form.py +57 -10
  76. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/note.py +2 -2
  77. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/tabcontent.py +8 -1
  78. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_board/action.py +1 -1
  79. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/model/field.py +38 -29
  80. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/model/group.py +4 -4
  81. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/model/record.py +17 -4
  82. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/screen/screen.py +25 -7
  83. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/calendar_gtk/calendar_.py +1 -1
  84. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/calendar_gtk/toolbar.py +1 -1
  85. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form.py +2 -1
  86. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/binary.py +3 -3
  87. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/calendar_.py +4 -4
  88. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/char.py +42 -5
  89. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/checkbox.py +3 -3
  90. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/dictionary.py +53 -15
  91. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/float.py +3 -7
  92. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/image.py +4 -4
  93. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/integer.py +1 -1
  94. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/many2many.py +3 -4
  95. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/many2one.py +2 -2
  96. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/multiselection.py +3 -3
  97. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/one2many.py +11 -8
  98. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/progressbar.py +2 -2
  99. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/pyson.py +3 -3
  100. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/reference.py +4 -4
  101. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/richtextbox.py +5 -5
  102. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/selection.py +3 -3
  103. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/state_widget.py +8 -6
  104. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/textbox.py +4 -4
  105. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/timedelta.py +3 -3
  106. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/url.py +2 -2
  107. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/widget.py +1 -1
  108. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/graph_gtk/bar.py +7 -7
  109. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/graph_gtk/graph.py +2 -2
  110. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/graph_gtk/line.py +5 -5
  111. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/graph_gtk/pie.py +2 -2
  112. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/list.py +110 -52
  113. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/list_gtk/editabletree.py +2 -2
  114. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/list_gtk/widget.py +22 -20
  115. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/screen_container.py +13 -1
  116. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/win_csv.py +2 -2
  117. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/win_export.py +9 -7
  118. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/win_form.py +73 -39
  119. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/win_import.py +5 -6
  120. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/wizard.py +11 -11
  121. {tryton-7.4.7 → tryton-7.6.0}/tryton/jsonrpc.py +2 -2
  122. {tryton-7.4.7 → tryton-7.6.0}/tryton/plugins/__init__.py +0 -1
  123. {tryton-7.4.7 → tryton-7.6.0}/tryton/pyson.py +18 -18
  124. {tryton-7.4.7 → tryton-7.6.0}/tryton/rpc.py +7 -5
  125. {tryton-7.4.7 → tryton-7.6.0}/tryton.egg-info/PKG-INFO +8 -7
  126. {tryton-7.4.7 → tryton-7.6.0}/tryton.egg-info/SOURCES.txt +2 -0
  127. {tryton-7.4.7 → tryton-7.6.0}/tryton.egg-info/requires.txt +2 -2
  128. tryton-7.4.7/tryton/bus.py +0 -99
  129. tryton-7.4.7/tryton/data/locale/de/LC_MESSAGES/tryton.mo +0 -0
  130. tryton-7.4.7/tryton/data/locale/es/LC_MESSAGES/tryton.mo +0 -0
  131. tryton-7.4.7/tryton/data/locale/es_419/LC_MESSAGES/tryton.mo +0 -0
  132. tryton-7.4.7/tryton/data/locale/et/LC_MESSAGES/tryton.mo +0 -0
  133. tryton-7.4.7/tryton/data/locale/fa/LC_MESSAGES/tryton.mo +0 -0
  134. tryton-7.4.7/tryton/data/locale/fr/LC_MESSAGES/tryton.mo +0 -0
  135. tryton-7.4.7/tryton/data/locale/hu/LC_MESSAGES/tryton.mo +0 -0
  136. tryton-7.4.7/tryton/data/locale/id/LC_MESSAGES/tryton.mo +0 -0
  137. tryton-7.4.7/tryton/data/locale/it/LC_MESSAGES/tryton.mo +0 -0
  138. tryton-7.4.7/tryton/data/locale/lo/LC_MESSAGES/tryton.mo +0 -0
  139. tryton-7.4.7/tryton/data/locale/lt/LC_MESSAGES/tryton.mo +0 -0
  140. tryton-7.4.7/tryton/data/locale/nl/LC_MESSAGES/tryton.mo +0 -0
  141. tryton-7.4.7/tryton/data/locale/pt/LC_MESSAGES/tryton.mo +0 -0
  142. tryton-7.4.7/tryton/data/locale/ro/LC_MESSAGES/tryton.mo +0 -0
  143. tryton-7.4.7/tryton/data/locale/tr/LC_MESSAGES/tryton.mo +0 -0
  144. tryton-7.4.7/tryton/data/locale/zh_CN/LC_MESSAGES/tryton.mo +0 -0
  145. tryton-7.4.7/tryton/data/pixmaps/tryton/tryton-note.svg +0 -4
  146. {tryton-7.4.7 → tryton-7.6.0}/LICENSE +0 -0
  147. {tryton-7.4.7 → tryton-7.6.0}/MANIFEST.in +0 -0
  148. {tryton-7.4.7 → tryton-7.6.0}/README.rst +0 -0
  149. {tryton-7.4.7 → tryton-7.6.0}/bin/tryton +0 -0
  150. {tryton-7.4.7 → tryton-7.6.0}/catalan.nsh +0 -0
  151. {tryton-7.4.7 → tryton-7.6.0}/doc/glossary.rst +0 -0
  152. {tryton-7.4.7 → tryton-7.6.0}/doc/index.rst +0 -0
  153. {tryton-7.4.7 → tryton-7.6.0}/doc/installation.rst +0 -0
  154. {tryton-7.4.7 → tryton-7.6.0}/doc/releases.rst +0 -0
  155. {tryton-7.4.7 → tryton-7.6.0}/doc/requirements-doc.txt +0 -0
  156. {tryton-7.4.7 → tryton-7.6.0}/doc/usage.rst +0 -0
  157. {tryton-7.4.7 → tryton-7.6.0}/english.nsh +0 -0
  158. {tryton-7.4.7 → tryton-7.6.0}/farsi.nsh +0 -0
  159. {tryton-7.4.7 → tryton-7.6.0}/french.nsh +0 -0
  160. {tryton-7.4.7 → tryton-7.6.0}/german.nsh +0 -0
  161. {tryton-7.4.7 → tryton-7.6.0}/make-darwin-installer.sh +0 -0
  162. {tryton-7.4.7 → tryton-7.6.0}/make-win32-installer.sh +0 -0
  163. {tryton-7.4.7 → tryton-7.6.0}/portuguese.nsh +0 -0
  164. {tryton-7.4.7 → tryton-7.6.0}/setup-freeze.py +0 -0
  165. {tryton-7.4.7 → tryton-7.6.0}/setup.nsi +0 -0
  166. {tryton-7.4.7 → tryton-7.6.0}/slovenian.nsh +0 -0
  167. {tryton-7.4.7 → tryton-7.6.0}/spanish.nsh +0 -0
  168. {tryton-7.4.7 → tryton-7.6.0}/tryton/action/__init__.py +0 -0
  169. {tryton-7.4.7 → tryton-7.6.0}/tryton/action/main.py +0 -0
  170. {tryton-7.4.7 → tryton-7.6.0}/tryton/cache.py +0 -0
  171. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/cellrendererbinary.py +0 -0
  172. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/cellrendererbutton.py +0 -0
  173. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/cellrendererclickablepixbuf.py +0 -0
  174. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/cellrenderercombo.py +0 -0
  175. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/cellrendererinteger.py +0 -0
  176. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/cellrenderertoggle.py +0 -0
  177. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/completion.py +0 -0
  178. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/datetime_.py +0 -0
  179. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/domain_inversion.py +0 -0
  180. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/entry_position.py +0 -0
  181. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/focus.py +0 -0
  182. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/htmltextbuffer.py +0 -0
  183. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/popup_menu.py +0 -0
  184. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/richtext.py +0 -0
  185. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/tempfile.py +0 -0
  186. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/timedelta.py +0 -0
  187. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/underline.py +0 -0
  188. {tryton-7.4.7 → tryton-7.6.0}/tryton/common/widget_style.py +0 -0
  189. {tryton-7.4.7 → tryton-7.6.0}/tryton/config.py +0 -0
  190. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/locale/ja_JP/LC_MESSAGES/tryton.po +0 -0
  191. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/LICENSE +0 -0
  192. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-add.svg +0 -0
  193. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-archive.svg +0 -0
  194. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-arrow-down.svg +0 -0
  195. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-arrow-left.svg +0 -0
  196. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-arrow-right.svg +0 -0
  197. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-arrow-up.svg +0 -0
  198. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-attach.svg +0 -0
  199. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-back.svg +0 -0
  200. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-barcode-scanner.svg +0 -0
  201. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-bookmark-border.svg +0 -0
  202. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-bookmark.svg +0 -0
  203. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-bookmarks.svg +0 -0
  204. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-cancel.svg +0 -0
  205. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-clear.svg +0 -0
  206. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-close.svg +0 -0
  207. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-copy.svg +0 -0
  208. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-create.svg +0 -0
  209. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-date.svg +0 -0
  210. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-delete.svg +0 -0
  211. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-download.svg +0 -0
  212. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-drag.svg +0 -0
  213. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-email.svg +0 -0
  214. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-error.svg +0 -0
  215. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-exit.svg +0 -0
  216. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-export.svg +0 -0
  217. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-filter.svg +0 -0
  218. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-format-align-center.svg +0 -0
  219. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-format-align-justify.svg +0 -0
  220. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-format-align-left.svg +0 -0
  221. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-format-align-right.svg +0 -0
  222. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-format-bold.svg +0 -0
  223. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-format-color-text.svg +0 -0
  224. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-format-italic.svg +0 -0
  225. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-format-underline.svg +0 -0
  226. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-forward.svg +0 -0
  227. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-history.svg +0 -0
  228. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-icon.png +0 -0
  229. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-icon.svg +0 -0
  230. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-import.svg +0 -0
  231. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-info.svg +0 -0
  232. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-launch.svg +0 -0
  233. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-link.svg +0 -0
  234. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-log.svg +0 -0
  235. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-menu.svg +0 -0
  236. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-ok.svg +0 -0
  237. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-open.svg +0 -0
  238. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-print.svg +0 -0
  239. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-public.svg +0 -0
  240. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-question.svg +0 -0
  241. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-refresh.svg +0 -0
  242. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-remove.svg +0 -0
  243. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-save.svg +0 -0
  244. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-search.svg +0 -0
  245. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-send.svg +0 -0
  246. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-sound-off.svg +0 -0
  247. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-sound-on.svg +0 -0
  248. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-star-border.svg +0 -0
  249. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-star.svg +0 -0
  250. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-switch.svg +0 -0
  251. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-translate.svg +0 -0
  252. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-unarchive.svg +0 -0
  253. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-undo.svg +0 -0
  254. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton-warning.svg +0 -0
  255. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton.icns +0 -0
  256. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton.ico +0 -0
  257. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/pixmaps/tryton/tryton.svg +0 -0
  258. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/sounds/LICENSE +0 -0
  259. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/sounds/danger.wav +0 -0
  260. {tryton-7.4.7 → tryton-7.6.0}/tryton/data/sounds/success.wav +0 -0
  261. {tryton-7.4.7 → tryton-7.6.0}/tryton/device_cookie.py +0 -0
  262. {tryton-7.4.7 → tryton-7.6.0}/tryton/exceptions.py +0 -0
  263. {tryton-7.4.7 → tryton-7.6.0}/tryton/fingerprints.py +0 -0
  264. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/__init__.py +0 -0
  265. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/main.py +0 -0
  266. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/__init__.py +0 -0
  267. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/about.py +0 -0
  268. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/code_scanner.py +0 -0
  269. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/dblogin.py +0 -0
  270. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/email_.py +0 -0
  271. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/infobar.py +0 -0
  272. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/limit.py +0 -0
  273. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/log.py +0 -0
  274. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/nomodal.py +0 -0
  275. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/preference.py +0 -0
  276. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/revision.py +0 -0
  277. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_board/__init__.py +0 -0
  278. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_board/view_board.py +0 -0
  279. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/__init__.py +0 -0
  280. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/model/__init__.py +0 -0
  281. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/screen/__init__.py +0 -0
  282. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/__init__.py +0 -0
  283. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/calendar_.py +0 -0
  284. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/calendar_gtk/__init__.py +0 -0
  285. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/calendar_gtk/dates_period.py +0 -0
  286. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/__init__.py +0 -0
  287. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/document.py +0 -0
  288. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/form_gtk/one2one.py +0 -0
  289. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/graph.py +0 -0
  290. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/graph_gtk/__init__.py +0 -0
  291. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/list_form.py +0 -0
  292. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/view_form/view/list_gtk/__init__.py +0 -0
  293. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/win_search.py +0 -0
  294. {tryton-7.4.7 → tryton-7.6.0}/tryton/gui/window/window.py +0 -0
  295. {tryton-7.4.7 → tryton-7.6.0}/tryton/plugins/translation/__init__.py +0 -0
  296. {tryton-7.4.7 → tryton-7.6.0}/tryton/tests/__init__.py +0 -0
  297. {tryton-7.4.7 → tryton-7.6.0}/tryton/tests/test_common.py +0 -0
  298. {tryton-7.4.7 → tryton-7.6.0}/tryton/tests/test_common_domain_parser.py +0 -0
  299. {tryton-7.4.7 → tryton-7.6.0}/tryton/tests/test_common_selection.py +0 -0
  300. {tryton-7.4.7 → tryton-7.6.0}/tryton/tests/test_common_timedelta.py +0 -0
  301. {tryton-7.4.7 → tryton-7.6.0}/tryton/translate.py +0 -0
  302. {tryton-7.4.7 → tryton-7.6.0}/tryton.desktop +0 -0
  303. {tryton-7.4.7 → tryton-7.6.0}/tryton.egg-info/dependency_links.txt +0 -0
  304. {tryton-7.4.7 → tryton-7.6.0}/tryton.egg-info/not-zip-safe +0 -0
  305. {tryton-7.4.7 → tryton-7.6.0}/tryton.egg-info/top_level.txt +0 -0
@@ -1,38 +1,13 @@
1
1
 
2
- Version 7.4.7 - 2025-04-02
2
+ Version 7.6.0 - 2025-04-28
3
3
  --------------------------
4
4
  * Bug fixes (see mercurial logs for details)
5
-
6
-
7
- Version 7.4.6 - 2025-03-04
8
- --------------------------
9
- * Bug fixes (see mercurial logs for details)
10
-
11
-
12
- Version 7.4.5 - 2025-02-16
13
- --------------------------
14
- * Bug fixes (see mercurial logs for details)
15
-
16
-
17
- Version 7.4.4 - 2025-01-16
18
- --------------------------
19
- * Bug fixes (see mercurial logs for details)
20
-
21
-
22
- Version 7.4.3 - 2025-01-01
23
- --------------------------
24
- * Bug fixes (see mercurial logs for details)
25
-
26
-
27
- Version 7.4.2 - 2024-12-16
28
- --------------------------
29
- * Bug fixes (see mercurial logs for details)
30
-
31
-
32
- Version 7.4.1 - 2024-12-01
33
- --------------------------
34
- * Bug fixes (see mercurial logs for details)
35
-
5
+ * Allow column widths to be reset
6
+ * Add simple chat widget on sidebar
7
+ * Remove support for Python 3.8
8
+ * Add support for Python 3.13
9
+ * Support color as type of icon and image
10
+ * Support color widget on form view
36
11
 
37
12
  Version 7.4.0 - 2024-11-04
38
13
  --------------------------
@@ -2,10 +2,10 @@ Copyright (C) 2004-2008 Tiny SPRL.
2
2
  Copyright (C) 2007-2009 Lorenzo Gil Sanchez.
3
3
  Copyright (C) 2007-2013 Bertrand Chenal.
4
4
  Copyright (C) 2007-2025 Cédric Krier.
5
- Copyright (C) 2008-2011 Udo Spallek.
5
+ Copyright (C) 2008-2025 Udo Spallek.
6
6
  Copyright (C) 2008-2011 virtual things - Preisler & Spallek GbR.
7
7
  Copyright (C) 2008-2025 B2CK SPRL.
8
- Copyright (C) 2010-2024 Nicolas Évrard.
8
+ Copyright (C) 2010-2025 Nicolas Évrard.
9
9
  Copyright (C) 2011-2012 Rodrigo Hübner.
10
10
  Copyright (C) 2012-2013 Antoine Smolders.
11
11
  Copyright (C) 2020-2021 Maxime Richez
@@ -1,9 +1,9 @@
1
- Metadata-Version: 2.2
1
+ Metadata-Version: 2.4
2
2
  Name: tryton
3
- Version: 7.4.7
3
+ Version: 7.6.0
4
4
  Summary: Tryton desktop client
5
5
  Home-page: http://www.tryton.org/
6
- Download-URL: http://downloads.tryton.org/7.4/
6
+ Download-URL: http://downloads.tryton.org/7.6/
7
7
  Author: Tryton
8
8
  Author-email: foundation@tryton.org
9
9
  License: GPL-3
@@ -42,21 +42,21 @@ Classifier: Natural Language :: Japanese
42
42
  Classifier: Natural Language :: Ukrainian
43
43
  Classifier: Operating System :: OS Independent
44
44
  Classifier: Programming Language :: Python :: 3
45
- Classifier: Programming Language :: Python :: 3.8
46
45
  Classifier: Programming Language :: Python :: 3.9
47
46
  Classifier: Programming Language :: Python :: 3.10
48
47
  Classifier: Programming Language :: Python :: 3.11
49
48
  Classifier: Programming Language :: Python :: 3.12
49
+ Classifier: Programming Language :: Python :: 3.13
50
50
  Classifier: Topic :: Office/Business
51
- Requires-Python: >=3.8
51
+ Requires-Python: >=3.9
52
52
  License-File: LICENSE
53
53
  Requires-Dist: pycairo
54
54
  Requires-Dist: python-dateutil
55
- Requires-Dist: PyGObject<3.51,>=3.19
55
+ Requires-Dist: PyGObject>=3.19
56
56
  Provides-Extra: calendar
57
57
  Requires-Dist: GooCalendar>=0.7; extra == "calendar"
58
58
  Provides-Extra: sound
59
- Requires-Dist: playsound; extra == "sound"
59
+ Requires-Dist: playsound3; extra == "sound"
60
60
  Dynamic: author
61
61
  Dynamic: author-email
62
62
  Dynamic: classifier
@@ -65,6 +65,7 @@ Dynamic: download-url
65
65
  Dynamic: home-page
66
66
  Dynamic: keywords
67
67
  Dynamic: license
68
+ Dynamic: license-file
68
69
  Dynamic: platform
69
70
  Dynamic: project-url
70
71
  Dynamic: provides-extra
@@ -47,6 +47,12 @@ info = get_info()
47
47
 
48
48
  html_theme = 'sphinx_book_theme'
49
49
  html_theme_options = {
50
+ 'logo': {
51
+ 'alt_text': "Tryton Documentation",
52
+ 'image_light': 'https://docs.tryton.org/logo-light.svg',
53
+ 'image_dark': 'https://docs.tryton.org/logo-dark.svg',
54
+ 'link': base_url,
55
+ },
50
56
  'repository_provider': 'gitlab',
51
57
  'repository_url': 'https://code.tryton.org/tryton',
52
58
  'repository_branch': info['branch'],
@@ -2,7 +2,7 @@
2
2
  copyright_holder = Tryton
3
3
  msgid_bugs_address = issue_tracker@tryton.org
4
4
  output_file = tryton/data/locale/tryton.pot
5
- keywords = _, gettext
5
+ keywords = _ gettext N_:1,2 ngettext:1,2
6
6
 
7
7
  [init_catalog]
8
8
  domain = tryton
@@ -124,24 +124,24 @@ dist = setup(name=name,
124
124
  'Natural Language :: Ukrainian',
125
125
  'Operating System :: OS Independent',
126
126
  'Programming Language :: Python :: 3',
127
- 'Programming Language :: Python :: 3.8',
128
127
  'Programming Language :: Python :: 3.9',
129
128
  'Programming Language :: Python :: 3.10',
130
129
  'Programming Language :: Python :: 3.11',
131
130
  'Programming Language :: Python :: 3.12',
131
+ 'Programming Language :: Python :: 3.13',
132
132
  'Topic :: Office/Business',
133
133
  ],
134
134
  platforms='any',
135
135
  license='GPL-3',
136
- python_requires='>=3.8',
136
+ python_requires='>=3.9',
137
137
  install_requires=[
138
138
  'pycairo',
139
139
  "python-dateutil",
140
- 'PyGObject>=3.19,<3.51',
140
+ 'PyGObject>=3.19',
141
141
  ],
142
142
  extras_require={
143
143
  'calendar': ['GooCalendar>=0.7'],
144
- 'sound': ['playsound'],
144
+ 'sound': ['playsound3'],
145
145
  },
146
146
  zip_safe=False,
147
147
  **args
@@ -1,5 +1,5 @@
1
1
  [tox]
2
- envlist = py38,py39,py310,py311,py312
2
+ envlist = py38,py39,py310,py311,py312,py313
3
3
 
4
4
  [testenv]
5
5
  usedevelop = true
@@ -1,6 +1,6 @@
1
1
  # This file is part of Tryton. The COPYRIGHT file at the top level of
2
2
  # this repository contains the full copyright notices and license terms.
3
- __version__ = "7.4.7"
3
+ __version__ = "7.6.0"
4
4
  import locale
5
5
 
6
6
  import gi
@@ -0,0 +1,143 @@
1
+ # This file is part of Tryton. The COPYRIGHT file at the top level of
2
+ # this repository contains the full copyright notices and license terms.
3
+ import base64
4
+ import json
5
+ import logging
6
+ import socket
7
+ import threading
8
+ import time
9
+ import uuid
10
+ from collections import defaultdict
11
+ from urllib.error import HTTPError
12
+ from urllib.request import Request, urlopen
13
+
14
+ from gi.repository import GLib
15
+
16
+ from tryton.config import CONFIG
17
+ from tryton.jsonrpc import object_hook
18
+
19
+ logger = logging.getLogger(__name__)
20
+
21
+
22
+ class Bus:
23
+
24
+ ID = str(uuid.uuid4())
25
+ current_thread = None
26
+ channel_actions = defaultdict(list)
27
+ listening = False
28
+
29
+ @classmethod
30
+ def listen(cls, connection):
31
+ if not CONFIG['thread']:
32
+ return
33
+ listener = threading.Thread(
34
+ target=cls._listen, args=(connection,), daemon=True)
35
+ listener.start()
36
+ cls.current_thread = listener.ident
37
+
38
+ @classmethod
39
+ def _listen(cls, connection):
40
+ bus_timeout = CONFIG['client.bus_timeout']
41
+ session = connection.session
42
+ authorization = base64.b64encode(session.encode('utf-8'))
43
+ headers = {
44
+ 'Content-Type': 'application/json',
45
+ 'Authorization': b'Session ' + authorization,
46
+ }
47
+
48
+ thread_id = threading.get_ident()
49
+ wait = 1
50
+ last_message = None
51
+ url = None
52
+ while connection.session == session:
53
+ if url is None:
54
+ if connection.url is None:
55
+ time.sleep(1)
56
+ continue
57
+ url = connection.url + '/bus'
58
+ cls.listening = True
59
+
60
+ channels = list(cls.channel_actions)
61
+ request = Request(url,
62
+ data=json.dumps({
63
+ 'last_message': last_message,
64
+ 'channels': channels,
65
+ }).encode('utf-8'),
66
+ headers=headers)
67
+ logger.info('poll channels %s with last message %s',
68
+ channels, last_message)
69
+ try:
70
+ response = urlopen(request, timeout=bus_timeout)
71
+ wait = 1
72
+ except socket.timeout:
73
+ wait = 1
74
+ continue
75
+ except Exception as error:
76
+ if thread_id != cls.current_thread:
77
+ break
78
+ if isinstance(error, HTTPError):
79
+ if error.code in (301, 302, 303, 307, 308):
80
+ url = error.headers.get('Location')
81
+ continue
82
+ elif error.code == 501:
83
+ logger.info("Bus not supported")
84
+ break
85
+ logger.error(
86
+ "An exception occurred while connecting to the bus. "
87
+ "Sleeping for %s seconds",
88
+ wait, exc_info=error)
89
+ cls.listening = False
90
+ time.sleep(min(wait, bus_timeout))
91
+ wait *= 2
92
+ continue
93
+
94
+ if connection.session != session:
95
+ break
96
+ if thread_id != cls.current_thread:
97
+ break
98
+
99
+ data = json.loads(response.read(), object_hook=object_hook)
100
+ if data['message']:
101
+ last_message = data['message']['message_id']
102
+ GLib.idle_add(cls.handle, data['channel'], data['message'])
103
+ cls.listening = False
104
+
105
+ @classmethod
106
+ def handle(cls, channel, message):
107
+ for callback in cls.channel_actions[channel]:
108
+ callback(message)
109
+
110
+ @classmethod
111
+ def register(cls, channel, function):
112
+ from tryton import rpc
113
+
114
+ restart = channel not in cls.channel_actions
115
+ cls.channel_actions[channel].append(function)
116
+ if restart:
117
+ # We can not really abort a thread, so we will just start a new one
118
+ # and ignore the result of the one already running
119
+ Bus.listen(rpc.CONNECTION)
120
+
121
+ @classmethod
122
+ def unregister(cls, channel, function):
123
+ try:
124
+ cls.channel_actions[channel].remove(function)
125
+ except ValueError:
126
+ pass
127
+
128
+ if not cls.channel_actions[channel]:
129
+ del cls.channel_actions[channel]
130
+
131
+
132
+ def popup_notification(message):
133
+ if message['type'] != 'notification':
134
+ return
135
+
136
+ from tryton.gui.main import Main
137
+ app = Main()
138
+ app.show_notification(
139
+ message.get('title', ''), message.get('body', ''),
140
+ message.get('priority', 1))
141
+
142
+
143
+ Bus.register(f'client:{Bus.ID}', popup_notification)
@@ -0,0 +1,179 @@
1
+ # This file is part of Tryton. The COPYRIGHT file at the top level of
2
+ # this repository contains the full copyright notices and license terms.
3
+ import gettext
4
+
5
+ from gi.repository import Gdk, Gio, GObject, Gtk
6
+
7
+ from tryton import common, rpc
8
+ from tryton.bus import Bus
9
+
10
+ _ = gettext.gettext
11
+
12
+
13
+ class MessageItem(GObject.GObject):
14
+
15
+ def __init__(self, message):
16
+ super().__init__()
17
+ self.message = message
18
+
19
+
20
+ class MessageList(GObject.GObject, Gio.ListModel):
21
+
22
+ def __init__(self):
23
+ super().__init__()
24
+ self._messages = []
25
+ self._items = {}
26
+
27
+ def do_get_item(self, position):
28
+ if position >= len(self._messages):
29
+ return None
30
+ message = self._messages[position]
31
+ if message['id'] not in self._items:
32
+ self._items[message['id']] = MessageItem(message)
33
+ return self._items[message['id']]
34
+
35
+ def do_get_item_type(self):
36
+ return MessageItem
37
+
38
+ def do_get_n_items(self):
39
+ return len(self._messages)
40
+
41
+ def clear(self):
42
+ self.emit('items-changed', 0, len(self._messages), 0)
43
+ self._messages = []
44
+ self._items = {}
45
+
46
+ def append(self, message):
47
+ self._messages.append(message)
48
+ self.emit('items-changed', len(self._messages) - 1, 0, 1)
49
+
50
+
51
+ class Chat:
52
+
53
+ def __init__(self, record):
54
+ self.record = record
55
+ Bus.register(f"chat:{self.record}", self.notify)
56
+ self.widget = self.__build()
57
+
58
+ def unregister(self):
59
+ Bus.unregister(f"chat:{self.record}", self.notify)
60
+
61
+ def send_message(self, message, internal):
62
+ rpc.execute(
63
+ 'model', 'ir.chat.channel', 'post', self.record, message,
64
+ 'internal' if internal else 'public', rpc.CONTEXT)
65
+
66
+ def get_messages(self):
67
+ return rpc.execute(
68
+ 'model', 'ir.chat.channel', 'get', self.record, rpc.CONTEXT)
69
+
70
+ def notify(self, message):
71
+ self.refresh()
72
+
73
+ def refresh(self):
74
+ self._messages.clear()
75
+ for post in self.get_messages():
76
+ self._messages.append(post)
77
+ self.widget.show_all()
78
+
79
+ def scroll_to_bottom(*args):
80
+ self._messages_sw.disconnect(signal_id)
81
+ vadj = self._messages_sw.get_vadjustment()
82
+ vadj.props.value = vadj.get_upper()
83
+ signal_id = self._messages_sw.connect(
84
+ 'size-allocate', scroll_to_bottom)
85
+
86
+ def __build(self):
87
+ widget = Gtk.VBox()
88
+ widget.set_spacing(3)
89
+
90
+ def _submit(button):
91
+ buffer = input_.get_buffer()
92
+ self.send_message(
93
+ buffer.get_text(
94
+ buffer.get_start_iter(), buffer.get_end_iter(), False),
95
+ internal.get_active())
96
+ buffer.set_text('')
97
+ if not Bus.listening:
98
+ self.refresh()
99
+
100
+ def _keypress(entry, event):
101
+ if (event.state & Gdk.ModifierType.CONTROL_MASK
102
+ and event.keyval == Gdk.KEY_Return):
103
+ _submit(None)
104
+ return True
105
+
106
+ self._messages = MessageList()
107
+ chat_messages = Gtk.ListBox.new()
108
+ chat_messages.props.activate_on_single_click = False
109
+ chat_messages.set_selection_mode(Gtk.SelectionMode.NONE)
110
+ chat_messages.bind_model(self._messages, self.create_message)
111
+ self._messages_sw = scrolledwindow = Gtk.ScrolledWindow()
112
+ viewport = Gtk.Viewport()
113
+ viewport.add(chat_messages)
114
+ viewport.set_valign(Gtk.Align.END)
115
+ scrolledwindow.set_shadow_type(Gtk.ShadowType.NONE)
116
+ scrolledwindow.set_policy(
117
+ Gtk.PolicyType.AUTOMATIC, Gtk.PolicyType.AUTOMATIC)
118
+ scrolledwindow.add(viewport)
119
+ widget.pack_start(scrolledwindow, True, True, 0)
120
+
121
+ input_ = Gtk.TextView()
122
+ input_.connect('key-press-event', _keypress)
123
+ input_.set_size_request(-1, 100)
124
+ widget.pack_start(input_, False, True, 0)
125
+
126
+ internal = Gtk.CheckButton.new_with_mnemonic(
127
+ _("Make this an _internal message"))
128
+ widget.pack_start(internal, False, True, 0)
129
+
130
+ submit = Gtk.Button.new_with_label(_("Send"))
131
+ submit.connect('clicked', _submit)
132
+ widget.pack_start(submit, False, False, 0)
133
+
134
+ return widget
135
+
136
+ def create_message(self, item):
137
+ message = item.message
138
+
139
+ row = Gtk.ListBoxRow()
140
+ row.set_selectable(False)
141
+ row.set_margin_top(5)
142
+
143
+ hbox = Gtk.HBox(spacing=10)
144
+ row.add(hbox)
145
+
146
+ if avatar_url := message.get('avatar_url'):
147
+ image = Gtk.Image()
148
+ pixbuf = common.IconFactory.get_pixbuf_url(
149
+ avatar_url, size=32, size_param='s',
150
+ callback=image.set_from_pixbuf)
151
+ image.set_from_pixbuf(pixbuf)
152
+ image.set_valign(Gtk.Align.START)
153
+ hbox.pack_start(image, False, False, 0)
154
+
155
+ bubble = Gtk.VBox()
156
+ hbox.pack_end(bubble, True, True, 0)
157
+
158
+ author = Gtk.Label(label=message['author'])
159
+ author.set_xalign(0)
160
+ author.get_style_context().add_class('dim')
161
+ timestamp = Gtk.Label(label=message['timestamp'].strftime('%x %X'))
162
+ timestamp.set_xalign(1)
163
+ timestamp.get_style_context().add_class('dim')
164
+
165
+ meta = Gtk.HBox()
166
+ meta.pack_start(author, True, True, 0)
167
+ meta.pack_end(timestamp, False, False, 0)
168
+
169
+ content = Gtk.Label(label=message['content'])
170
+ content.set_xalign(0)
171
+ content.set_line_wrap(True)
172
+ content.set_selectable(True)
173
+ content.get_style_context().add_class(
174
+ f"chat-content-{message['audience']}")
175
+
176
+ bubble.pack_start(meta, False, False, 0)
177
+ bubble.pack_start(content, False, False, 0)
178
+
179
+ return row
@@ -33,6 +33,13 @@ def main():
33
33
  label.warning {
34
34
  color: @warning_color;
35
35
  }
36
+ label.dim {
37
+ font-size: smaller;
38
+ font-weight: lighter;
39
+ }
40
+ .chat-content-internal {
41
+ font-weight: lighter;
42
+ }
36
43
  .window-title, .wizard-title {
37
44
  font-size: large;
38
45
  font-weight: bold;
@@ -2,17 +2,18 @@
2
2
  # this repository contains the full copyright notices and license terms.
3
3
  from . import timedelta
4
4
  from .common import (
5
- COLOR_SCHEMES, MODELACCESS, MODELHISTORY, MODELNAME, MODELNOTIFICATION,
6
- TRYTON_ICON, VIEW_SEARCH, IconFactory, Logout, RPCContextReload,
7
- RPCException, RPCExecute, RPCProgress, Tooltips, apply_label_attributes,
8
- ask, check_version, concurrency, data2pixbuf, date_format, ellipsize,
9
- error, file_open, file_selection, file_write, filter_domain,
10
- generateColorscheme, get_align, get_credentials, get_gdk_backend,
11
- get_hostname, get_port, get_sensible_widget, get_toplevel_window, hex2rgb,
12
- highlight_rgb, humanize, idle_add, mailto, message, node_attributes,
13
- open_documentation, play_sound, process_exception, resize_pixbuf,
14
- selection, setup_window, slugify, sur, sur_3b, timezoned_date, to_xml,
15
- untimezoned_date, url_open, userwarning, warning)
5
+ COLOR_SCHEMES, MODELACCESS, MODELCHAT, MODELHISTORY, MODELNAME,
6
+ MODELNOTIFICATION, TRYTON_ICON, VIEW_SEARCH, IconFactory, Logout,
7
+ RPCContextReload, RPCException, RPCExecute, RPCProgress, SolidColorFactory,
8
+ Tooltips, apply_label_attributes, ask, check_version, concurrency,
9
+ data2pixbuf, date_format, ellipsize, error, file_open, file_selection,
10
+ file_write, filter_domain, generateColorscheme, get_align, get_credentials,
11
+ get_gdk_backend, get_hostname, get_monitor_size, get_port,
12
+ get_sensible_widget, get_toplevel_window, hex2rgb, highlight_rgb, humanize,
13
+ idle_add, mailto, message, node_attributes, open_documentation, play_sound,
14
+ process_exception, resize_pixbuf, selection, setup_window, slugify, sur,
15
+ sur_3b, timezoned_date, to_xml, untimezoned_date, url_open, userwarning,
16
+ warning)
16
17
  from .domain_inversion import (
17
18
  concat, domain_inversion, eval_domain, extract_reference_models,
18
19
  filter_leaf, inverse_leaf, localize_domain, merge,
@@ -28,10 +29,12 @@ __all__ = [
28
29
  MODELHISTORY,
29
30
  MODELNAME,
30
31
  MODELNOTIFICATION,
32
+ MODELCHAT,
31
33
  RPCContextReload,
32
34
  RPCException,
33
35
  RPCExecute,
34
36
  RPCProgress,
37
+ SolidColorFactory,
35
38
  TRYTON_ICON,
36
39
  Tooltips,
37
40
  VIEW_SEARCH,
@@ -57,6 +60,7 @@ __all__ = [
57
60
  get_credentials,
58
61
  get_gdk_backend,
59
62
  get_hostname,
63
+ get_monitor_size,
60
64
  get_port,
61
65
  get_sensible_widget,
62
66
  get_toplevel_window,
@@ -14,7 +14,7 @@ class Button(Gtk.Button):
14
14
  def __init__(self, attrs=None):
15
15
  self.attrs = attrs or {}
16
16
  self.label = '_' + attrs.get('string', '').replace('_', '__')
17
- super(Button, self).__init__(label=self.label, stock=None,
17
+ super().__init__(label=self.label, stock=None,
18
18
  use_underline=True)
19
19
  self._set_icon(attrs.get('icon'))
20
20
 
@@ -10,7 +10,7 @@ from .cellrendererinteger import CellRendererInteger
10
10
  class CellRendererFloat(CellRendererInteger):
11
11
 
12
12
  def __init__(self):
13
- super(CellRendererFloat, self).__init__()
13
+ super().__init__()
14
14
  self.digits = None
15
15
  self.monetary = False
16
16
  self.convert = float
@@ -6,7 +6,7 @@ from gi.repository import GObject, Gtk
6
6
  class CellRendererText(Gtk.CellRendererText):
7
7
 
8
8
  def __init__(self):
9
- super(CellRendererText, self).__init__()
9
+ super().__init__()
10
10
  self.connect('editing-started', self.__class__.on_editing_started)
11
11
 
12
12
  def on_editing_started(self, editable, path):
@@ -16,7 +16,7 @@ class CellRendererText(Gtk.CellRendererText):
16
16
  class CellRendererTextCompletion(CellRendererText):
17
17
 
18
18
  def __init__(self, set_completion):
19
- super(CellRendererTextCompletion, self).__init__()
19
+ super().__init__()
20
20
  self.set_completion = set_completion
21
21
 
22
22
  def on_editing_started(self, editable, path):