Commit Graph

179 Commits

Author SHA1 Message Date
Philipp Hörist f89347516f Only use absolute imports from gtk module
- This reduces import cycles
2018-09-26 19:06:47 +02:00
Philipp Hörist 74b66837fa Add annotations
- Remove some unused vars from app
2018-09-21 15:46:52 +02:00
Philipp Hörist 385ef2e456 Fix pylint errors
- duplicate-key
- eval-used
- comparison-with-callable
2018-09-18 17:02:14 +02:00
Philipp Hörist 31a500245f Fix unneeded-not pylint errors 2018-09-18 16:03:35 +02:00
Philipp Hörist 1680c3bb38 Fix pylint errors
- consider-using-enumerate
- unneeded-not
- unidiomatic-typecheck
2018-09-18 15:24:40 +02:00
Philipp Hörist 8483ba503f Fix unnecessary-pass pylint errors 2018-09-18 14:03:58 +02:00
Philipp Hörist ccc06a04ab Fix bad-whitespace pylint errors 2018-09-18 12:06:01 +02:00
Philipp Hörist ff6ca57033 Fix no-else-return pylint errors 2018-09-18 10:16:54 +02:00
Philipp Hörist e8ac644440 Fix unused-variable pylint errors 2018-09-17 21:16:19 +02:00
Philipp Hörist 7bb6f8b22e Fix bare-except pylint errors 2018-09-16 23:45:01 +02:00
Philipp Hörist c6547b6d30 Fix superfluous-parens pylint errors 2018-09-16 14:42:18 +02:00
Philipp Hörist 49ca238252 Fix len-as-condition pylint errors 2018-09-16 01:10:04 +02:00
Philipp Hörist d54d4bc232 Add annotations and fix pylint/mypy errors 2018-09-13 23:56:12 +02:00
Philipp Hörist b99632ab03 Fix pylint errors 2018-09-12 00:01:54 +02:00
Philipp Hörist 0fba2b8a58 Add debug output for NetworkMonitor 2018-09-10 20:27:22 +02:00
Philipp Hörist a4a136566f Fix license comment format
every linter flags this as an error
2018-09-05 02:59:34 +02:00
André Apitzsch b8444fec64 music_track_listener: recognize playing song
when listener is enabled
2018-09-02 18:58:28 +02:00
Philipp Hörist e665ee1fbe Fix MUC invite notification
Fixes #9309
2018-08-24 22:03:33 +02:00
Philipp Hörist 1c69b92d85 Move filechoosers into gtk module 2018-08-19 17:47:17 +02:00
Yann Leboulanger c49f9d60ab fix jingle negotiation from an XMPP point of view 2018-08-18 16:05:33 +02:00
André Apitzsch 7447f33c5e Port remote control to GDBus 2018-08-17 22:06:02 +02:00
Philipp Hörist 5feb4becfd Rework Emoji implementation
- Use emoji data from a generated dict based on the offical unicode docs,
this makes it easier to update in the future
- Rewrite the emoji chooser
- Add a search field to the emoji chooser
- The emoji chooser is loaded async
- Update to current Unicode 11 Noto theme
2018-08-17 21:55:42 +02:00
Philipp Hörist e37ab6b59a Fix typo 2018-08-17 09:37:43 +02:00
Philipp Hörist 9d5131b8b4 Rework Gajim Theming
- Save all Theme settings to .css instead of the config file
- Add a gajim-dark.css
- Refactor the ThemesWindow
2018-08-16 22:53:33 +02:00
Sophie Herold ee3cc9cbab Reduce number of notifications kept in message tray 2018-08-16 22:48:40 +02:00
Philipp Hörist c778ed6917 Move Preferences into own module
- Port Preferences to Gtk.ApplicationWindow
2018-08-06 19:48:49 +02:00
Philipp Hörist 043e764896 Make Service Registration a Gtk.Assistant
- Move all xmpp Register methods into the register module
2018-08-04 19:47:57 +02:00
Philipp Hörist db77fa1ace Add roster implementation to Gajim 2018-07-26 20:38:00 +02:00
Philipp Hörist 78e4e20d49 Move ProfileWindow into gtk module 2018-07-22 16:53:02 +02:00
Philipp Hörist 07c87a4194 Rewrite discovery code and move it into own module 2018-07-22 16:20:00 +02:00
Philipp Hörist 78858f7c82 Move more MUC methods into muc module 2018-07-22 16:19:53 +02:00
Philipp Hörist 3a3b5aff20 Move some dialogs into gtk module 2018-07-18 00:15:46 +02:00
Philipp Hörist bff5f14b92 Move invites into MUC module 2018-07-17 18:38:36 +02:00
Philipp Hörist ebbe06d587 Refactor MAM into own module
- Rework the MAM Preference dialog
- Move MAM Preference dialog into a new gtk module
- Refactor all MAM code into own module
- Refactor the MAM code itself so we can easier test it in the future
- Add a misc module for smaller XEPs and move EME, Last Message Correction
Delay, OOB into it
- Add dedicated module for XEP-0082 Time Profiles
2018-07-15 14:26:00 +02:00
Ave O c3a359ba23
Change to gender-neutral alternatives of pronouns 2018-07-11 23:15:56 +03:00
Philipp Hörist eb1b6f605a Dump certificate before writing it to storage 2018-07-09 20:15:13 +02:00
Philipp Hörist 4bcdbde2c8 Move httpupload into modules 2018-07-07 01:49:50 +02:00
Philipp Hörist d45fa13ee9 Refactor atom into new module and disable it
Gajim lacks a good UI for microblogging

Fixes #9218
2018-07-06 21:02:06 +02:00
Philipp Hörist bbf3a544e8 Refactor UserLocation into own module 2018-07-05 19:38:03 +02:00
Philipp Hörist 14f088c2d9 Refactor UserMood into own module 2018-07-05 19:37:51 +02:00
Philipp Hörist a4350a812b Refactor UserTune into own module 2018-07-05 00:16:42 +02:00
Philipp Hörist b7775afd0c Refactor UserActivity and PEP into own modules 2018-07-03 20:00:31 +02:00
Philipp Hörist 2ca0ca38a5 Refactor Pubsub/Bookmarks/UserAvatar into own modules 2018-07-01 22:35:56 +02:00
Philipp Hörist 0dde1759e8 Make Profile a GtkApplicationWindow
Fixes #9180
2018-07-01 13:30:13 +02:00
Alexander Krotov 7fa4c9e1c2 Spellcheck 2018-06-28 23:37:34 +02:00
Philipp Hörist 129f72bf8e Refactor http auth code into own module 2018-06-25 23:47:06 +02:00
Alexander Krotov d871dcdcb1 More spelling fixes 2018-06-22 01:47:29 +03:00
Philipp Hörist 631740b66b MUC: Fix voice request
Fixes #9159
2018-06-01 20:58:09 +02:00
Philipp Hörist 4bed8ace95 Refactor Notifications
- Use icon names instead of path
- Move PopupNotificationWindow into notify.py
- Make popup class method instead of module method
- Dont use sessions to get control on notification action Fixes #9140
- Add has_focus() method to ChatControlBase
2018-06-01 17:48:05 +02:00
Philipp Hörist 32b74b459e Remove support for ESessions
Fixes #5294
2018-05-28 18:21:45 +02:00
Philipp Hörist b749eccf51 Fix idle detection
Fixes #9149
2018-05-27 10:51:57 +02:00
Philipp Hörist c5df74c509 Refactor idle module
- Get rid of sleepy.py, handle everything in idle.py
- Introduce one Monitor class that handles everything
2018-05-21 02:32:33 +02:00
Philipp Hörist 2636e3449f Refactor avatar publishing
- Publish avatars with a size of 200x200
- Add AvatarSize.PUBLISH so we can easily change it in the future
- Dont upscale small avatars on publish
- Use surfaces for displaying the avatar in ProfileWindow and VcardWindow
because this scales correctly on HiDPI screens
2018-05-20 01:28:12 +02:00
Philipp Hörist 3c22ab752a Bring control to front when notification is clicked
if autopopup_chat_opened is activated no control is found because
the event that triggered the notification is already deleted when
the notification is clicked by the user. So instead of searching
for the event, search for the control with jid/account.

Fixes #9124
2018-05-12 23:36:52 +02:00
Philipp Hörist c38db84e04 Refactor FileChooserDialogs
Use GtkFileChooserDialog only when we need previews, default to
NativeFileChooser otherwise.

GtkFileChooserDialogs have a long list of issues, so lets only use it
if we gain something from it.

Flatpak should only run NativeFileChoosers because its sandboxed and
this is needed for security purposes. As a result of that, Flatpak Users
dont have image previews in the FileOpenDialogs

Refactor all FileChoosers for a more simple approach when we use them

Add a new SendFileDialog, so we dont have to put widgets into the FileChooser
which forces non-native Dialogs.
2018-05-05 09:22:08 +02:00
Philipp Hörist bcf27cb3c1 Support for PKIX over Secure HTTP (POSH)
Fixes #9083
2018-05-01 21:08:26 +02:00
Philipp Hörist c534d3a147 Refactor SSL errors
Dont save fingerprints to config and check certs with our own methods.
We should trust openssl to do all necessary checks.

Self signed certs can be added to cacert.pem and will not show up as
an error until the cert changes.

nbxmpp now saves all ssl errors and passes them, so now we loop over
all errors until all are confirmed or ignored by the user

Also cacerts are now saved in utf-8
2018-05-01 14:03:20 +02:00
Philipp Hörist 105427b8fd Use consistent way to get paths
This lets us now import the app module without setting paths
2018-04-25 20:49:37 +02:00
Philipp Hörist e265514d88 Detect dependencys only on demand
This allows us to import the app module without triggering
dependency detection

Also add is_installed() for checking if a dependency is installed and
disable_dependency() in case we dont want to use a dependency
2018-04-24 19:36:33 +02:00
Philipp Hörist 4a26ecb12c Refactor configpaths
- init configpaths earlier so logging can access it to store debug logs
- First step for more consistency across Gajim when looking up paths

  Recommended usage for the future:
  app.configpaths.get()
  configpaths.get()
2018-04-21 12:48:57 +02:00
Philipp Hörist 290e761f88 Add support for Room Avatars
- Groupchats promote a vcard hash with presence

Refactoring:

- Dont delete groupchat contacts if they are maximized from the roster
- Roster and GroupchatControl use the same contact object
2018-04-19 22:11:41 +02:00
Yann Leboulanger a9a6b048fb set a transient_for for join groupchat dialog when needed. Fixes #8994 2018-03-28 16:14:54 +02:00
Philipp Hörist 6f55cf3dd4 Fix some problematic imports 2018-03-26 00:19:59 +02:00
Yann Leboulanger faa88819a1 improve some strings 2018-03-25 16:26:29 +02:00
Yann Leboulanger ba48e4530b don't just ignore when we receive an error to vcard request. Fixes #8965 2018-03-23 22:17:59 +01:00
Philipp Hörist 3d980fd6f5 Show image preview in filechooser dialog 2018-03-21 20:24:20 +01:00
Philipp Hörist abdca0eaac Fix TextView scrolling
Fixes #8813
2018-03-20 22:19:30 +01:00
Philipp Hörist 9de427f6fa Allow multiple file uploads
Fixes #8957
2018-03-17 20:44:14 +01:00
Philipp Hörist 8f2bc1e1c6 Handle connection lost notification click
Fixes #8823
2018-03-15 18:37:34 +01:00
Philipp Hörist 1935a4f40e Disable ZeroConf account by default 2018-03-07 20:24:08 +01:00
Philipp Hörist 52fa57795a Better emoticon theme fallback strategy
Fallback must be happening in init_emoticon() instead of PreferencesWindow
2018-02-22 00:37:54 +01:00
Philipp Hörist f1aceae214 Fix avatar ratio
Fixes #8907
2018-02-19 22:02:31 +01:00
Philipp Hörist 877b754ef3 Simplfy writing to config file
- use `with` statement and open() instead of os.open()
- execute run() on dialog, otherwise sys.exit() is called immediatly
2018-02-12 23:39:50 +01:00
Philipp Hörist 6deedb1743 Only use logind listener on linux 2018-01-29 23:12:58 +01:00
Philipp Hörist 232dc1dda0 Scale Avatars for HiDPI Screens 2018-01-29 00:06:31 +01:00
Bronko 3a3be94aa8 integrate httpupload plugin into gajim core
add new config option 'filetransfer_preference'
add drag and drop support for file upload
2018-01-22 17:29:27 +01:00
Philipp Hörist 71fb3d0b4f Improve network speed on Windows
Call select.select() with the smallest timeout possible
2018-01-21 21:52:32 +01:00
Philipp Hörist 4aadc00bd6 Revert "Improve speed of Windows client"
This reverts commit 45e3139bd0
2018-01-21 20:45:32 +01:00
Philipp Hörist 45e3139bd0 Improve speed of Windows client
This calls on each mainloop cylce select.select() instead of every
20 ms.
2018-01-20 23:21:39 +01:00
André Apitzsch 6f025a1d4a Remove some unused imports 2018-01-12 00:21:11 +01:00
André Apitzsch e89e7c3123 Port screensaver listening to GTK dbus 2018-01-05 23:33:37 +01:00
André Apitzsch 81a039854f Port music_track_listener to GTK dbus 2018-01-04 21:49:16 +01:00
Philipp Hörist 361ad92b26 Remove unused code 2017-12-29 19:08:05 +01:00
Philipp Hörist 23de7d5331 Use higher level API to focus windows
set_active_tab() already calls present(), no need to call it afterwards
again
2017-12-26 21:55:19 +01:00
André Apitzsch f3bde561a3 GUI interface: fix resource warning 2017-12-18 23:14:22 +01:00
Philipp Hörist e3effdcb6c Refactor SubscriptionWindow 2017-12-17 22:30:16 +01:00
Philipp Hörist 65593c613c Fix undefined var 2017-12-17 17:34:22 +01:00
Philipp Hörist 2c4c610632 Make sure our own JID is in the DB 2017-12-17 13:48:32 +01:00
Emmanuel Gil Peyrot f4cae17d9f Remove support for AWN, which isn’t maintained anymore 2017-12-13 23:19:16 +01:00
Yann Leboulanger 4e7fcea288 Merge branch 'logind' into 'master'
Port logind_listener to GTK dbus

See merge request gajim/gajim!167
2017-12-13 21:57:57 +01:00
Yann Leboulanger a39d68d4ae when internet connection is back, only connect accounts that were
connected before connection broke
2017-12-11 21:13:53 +01:00
André Apitzsch 5364c1980c Port logind_listener to GTK dbus 2017-12-09 15:04:15 +01:00
André Apitzsch be32d9afe6 Remove upower_listener
the 'Sleeping' signal has been removed from UPower about four years ago
https://cgit.freedesktop.org/upower/commit/src/org.freedesktop.UPower.xml?id=1ee642e705a63f5ad56a6b55e4bf5c4a64c959b8
2017-12-09 00:34:47 +01:00
Philipp Hörist 786ef96400 Port InformationEvent handling to new interface 2017-12-09 00:15:26 +01:00
Philipp Hörist 61ad783658 Add new interface to raise dialogs 2017-12-08 19:50:48 +01:00
Philipp Hörist beb9fa2f17 Merge branch 'location' into 'master'
Get location with GeoClue2

Closes #8772

See merge request gajim/gajim!164
2017-12-05 17:10:51 +01:00
André Apitzsch 2aab433932 Get location with GeoClue2 2017-12-04 21:00:20 +01:00
Philipp Hörist ace904573a Add new Join Groupchat dialog
- Complete rewrite of the old Groupchat dialog
- Has now a "minimal" mode, which is used if we have all infos for joining except the nickname and if we want to bookmark
- Handle xmpp uris received via command line
2017-12-03 23:58:02 +01:00
Philipp Hörist 553ba9e59f Dont preserve aspect ratio when loading an avatar
Clients should only upload square sized avatars
2017-12-03 23:58:02 +01:00
Philipp Hörist 1c895e8983 Persist resource across sessions
This was somehow lost once we implemented random resource strings
Although its good that initally a random resource is chosen, it
still should persist across sessions.

This helps to kill zombie client connections on the server because
most servers kill the old session once a new with the same resource
connects

Also dont notify the user about resource conflicts if no custom
resource is set. We should not expect users to know about resources
and what they are used for as long as possible.
2017-11-20 18:10:51 +01:00