summaryrefslogtreecommitdiff
path: root/pidgin/pidginapplication.c
Commit message (Collapse)AuthorAgeFilesLines
* Remove all of the current Mood APIGary Kramlich2023-03-201-13/+0
| | | | | | | | | | | The functionality of the mood api is being moved into PurplePresence via the soon to be added Emoji and Message properties. As such we have no need for the existing API which is why we are removing all of it. Testing Done: Ran `ninja pidgin-pot all tests` successfully and verified there were no new warnings. Reviewed at https://reviews.imfreedom.org/r/2366/
* Embed PidginAccountEditor into PidginAccountManagerGary Kramlich2023-03-161-7/+35
| | | | | | | | | | | | | | | | | The account manager now uses a stack to switch between a single editor instance and the list of accounts. The save button from the editor got moved next to the new back button, but we should probably prompt or throw up an info box when the user starts making changes or prompt before moving back. Also, the app.edit-account action now will lose any changes to an account that is currently being edited, which we should disallow from happening in the future as well. Testing Done: Opened the account manager and selected accounts and moved backed and saved accounts and made sure everything there worked. Opened the account editor from a connection error notification and verified that opened properly as well. Reviewed at https://reviews.imfreedom.org/r/2333/
* Display the preferences window as a singleton from the applicationGary Kramlich2023-02-211-2/+12
| | | | | | | | | | | This is how we handle displaying other dialogs and apparently the preferences window just got missed. We also make it transient for whatever window is active which means it won't fill an entire cell in a tiling window manager. Testing Done: Opened the preferences dialog in i3 and verified it was no longer a full tile and that everything worked as expected. Reviewed at https://reviews.imfreedom.org/r/2242/
* Remove PidginBlistGary Kramlich2023-02-171-3/+0
| | | | | | | | | | | | | | | | | | | | PidginContactList is functional enough for us to start adding features and since GtkTreeView is being deprecated, now seemed like a great time to purge PidginBlist. There's a few remaining pieces in gtkblist.[ch] relating to the join chat and im buddy dialogs, as well as the PurpleBlist subclass we need to work out yet. I also removed the gtkbuddynote plugin as all it did was add the buddy note to the tooltip. My future plans here will have this built in to the ui because a few protocols support this already and we can mock it for those that don't. Testing Done: Launched Pidgin 3 and verified stuff worked! Bugs closed: PIDGIN-17751 Reviewed at https://reviews.imfreedom.org/r/2228/
* Remove the privacy apiGary Kramlich2022-12-051-13/+0
| | | | | | | | | | | This API has been needing a rewrite for as long as I've been working on Gaim / Pidgin and nothing has come of it. Therefore, I'm am removing it for a much more simplified approach in the future. Testing Done: Sent some messages with the demo protocol plugin. Reviewed at https://reviews.imfreedom.org/r/2065/
* Bump C standard to C99 for Pidgin files and fix warningsElliott Sales de Andrade2022-11-281-47/+67
| | | | | | | | | Bump C standard to C99 for Pidgin files only and fix warnings Testing Done: Touched all Pidgin files, compiled and saw no new warnings. Reviewed at https://reviews.imfreedom.org/r/2103/
* Add a donate link under the help menu and move the debug window item to the ↵Gary Kramlich2022-11-231-0/+11
| | | | | | | | | tools menu Testing Done: Ran and verified the menu items work. Reviewed at https://reviews.imfreedom.org/r/2080/
* Display a dialog in Pidgin if purple_core_init returned FALSEGary Kramlich2022-11-011-5/+31
| | | | | | | | | | | | This also adds an environment variable so developers (or users for some reason) can set a custom error message for purple_core_init to return. The intent is to allow UI developers to control the message and make sure things display as they expect them to. Testing Done: used the `PURPLE3_CORE_ERROR_MESSAGE` environment variable to test the dialog including one with multiple lines of `a`'s with no breaks and everything displayed fine. Reviewed at https://reviews.imfreedom.org/r/2007/
* Add an out parameter for an error to purple_core_initGary Kramlich2022-10-311-3/+6
| | | | | | | | | Testing Done: Ran the unit tests, pidgin3 and finch3 without issue. Bugs closed: PIDGIN-17699 Reviewed at https://reviews.imfreedom.org/r/2004/
* Create PurpleUi that merges PurpleCoreUiOps and PurpleUiInfoGary Kramlich2022-10-311-9/+3
| | | | | | | | | | | | | This created a lot more refactoring that I imagined, but it's mostly just moving stuff around. I skipped the unit tests for now because we already have a `test_ui.[ch]` in the tests directory which we can/should move to a separate library or something, so it's available outside of the `libpurple/tests/` directory. Testing Done: Ran the unit tests, launched pidgin3, and launched finch3 with out issue. Bugs closed: PIDGIN-17697 Reviewed at https://reviews.imfreedom.org/r/1925/
* Disconnect the plugin state signals before we tell the core to shutdownGary Kramlich2022-10-281-0/+10
| | | | | | | | | | This avoids some issues where we were trying to save the state of plugins as they were being unloaded as part of the shutdown process. Testing Done: Ran with `G_DEBUG=fatal-warnings` in gdb and exited cleanly!! Reviewed at https://reviews.imfreedom.org/r/1989/
* Make the debug window transient for whatever window created it.Gary Kramlich2022-09-271-27/+22
| | | | | | | | | Testing Done: Opened the debug window in i3wm and verified it didn't take a full tile and worked as expected. Bugs closed: PIDGIN-17675 Reviewed at https://reviews.imfreedom.org/r/1845/
* Use the id property of PurpleUiInfo as the directory name to use with ↵Gary Kramlich2022-09-211-1/+1
| | | | | | | | | | | XDG_CONFIG_HOME Testing Done: Ran both finch and pidgin. Verified that they created `build/config/finch3` and `build/config/pidgin3` when run from a devenv environment. Also verified that `gtk-gaim.ini` in `build/config/pidgin3` was no named `build/config/pidgin3/pidgin3.ini`. Reviewed at https://reviews.imfreedom.org/r/1824/
* Make a bunch of windows transient and use gtk_window_present_with_time ↵Gary Kramlich2022-09-191-38/+43
| | | | | | | | | instead of just gtk_widget_show Testing Done: Opened all the windows and made sure they weren't full screen in my tiling window manager. Reviewed at https://reviews.imfreedom.org/r/1800/
* Rename pidginconversationwindow.[ch] to pidgindisplaywindow.[ch]Gary Kramlich2022-09-181-1/+1
| | | | | | | | | Testing Done: Ran and made sure I could open a conversation. Bugs closed: PIDGIN-17665 Reviewed at https://reviews.imfreedom.org/r/1792/
* Rename PidginConversationWindow to PidginDisplayWindow as it holds more than ↵Gary Kramlich2022-09-171-1/+1
| | | | | | | | | | | | | conversations now Renaming the files will come after this has landed. Testing Done: Opened a conversation. Bugs closed: PIDGIN-17657 Reviewed at https://reviews.imfreedom.org/r/1774/
* Add devel CSS to application windowsElliott Sales de Andrade2022-09-161-0/+4
| | | | | | | | | | | This adds a bit of styling on the header bar, which I guess you won't see without CSD. https://gnome.pages.gitlab.gnome.org/libadwaita/doc/main/style-classes.html#development-window Testing Done: Opened and saw a bit of striping on the title bar. Reviewed at https://reviews.imfreedom.org/r/1776/
* Replace calls to the old account editor with the new editor.Gary Kramlich2022-09-151-2/+3
| | | | | | | | | | | * Removed the temporary buttons in the account manager. * Pointed permanent buttons to the new editor * Updated the application action to open the new editor. Testing Done: Opened the account editor and verified that the add and remove buttons opened the new editor. Also verified that action opened the new editor. Reviewed at https://reviews.imfreedom.org/r/1771/
* Fix typo in signal nameElliott Sales de Andrade2022-09-061-1/+1
| | | | | | | Testing Done: Started up and saw one less warning. Reviewed at https://reviews.imfreedom.org/r/1730/
* Save loaded plugin state when they are loaded/unloadedElliott Sales de Andrade2022-09-051-0/+18
| | | | | | | | | Not sure if we need to resave on the failed signals, but it probably won't hurt anything. Testing Done: Enabled XMPP console, restarted and it was still enabled. Disabled XMPP console, restarted and it was still disabled. Reviewed at https://reviews.imfreedom.org/r/1717/
* Do our best to set a transient parent for all of our dialogsGary Kramlich2022-08-301-4/+56
| | | | | | | Testing Done: Opened all of the dialogs and verified that the `GWarning` was no where to be found. Reviewed at https://reviews.imfreedom.org/r/1698/
* Make Plugin window a singletonElliott Sales de Andrade2022-08-301-2/+7
| | | | | | | | | In the style of the account manager window. Testing Done: Open Plugin Manager, and then clicked the menu button again. No extra dialogs showed up. Reviewed at https://reviews.imfreedom.org/r/1693/
* Remove the custom css setup for now as it's throwing a GWarning and we need ↵Gary Kramlich2022-08-241-12/+0
| | | | | | | | | to plan this out more. Testing Done: Ran and verified the warning was gone. Reviewed at https://reviews.imfreedom.org/r/1636/
* Replace a gtk_widget_show_all with gtk_widget_showGary Kramlich2022-05-051-1/+1
| | | | | | | Testing Done: Compiled Reviewed at https://reviews.imfreedom.org/r/1416/
* Update PidginApplication for the changes in GTK4Gary Kramlich2022-02-221-19/+7
| | | | | | | Testing Done: Compiled and verified that `pidginapplication.c` no longer had any warnings or errors. Reviewed at https://reviews.imfreedom.org/r/1309/
* Replace libhandy with libadwaitaGary Kramlich2022-02-101-2/+2
| | | | | | | | | This actually fixes a ton of errors as libhandy requires gtk3, so we ended up with a ton of symbols being redefined and all that. So with this change, that all goes away. Testing Done: Compiled and verified that there was no mention of `handy`, `hdy`, `Hdy`, or `HDY` in the output. Reviewed at https://reviews.imfreedom.org/r/1294/
* Add source files to GObject introspectionElliott Sales de Andrade2022-08-021-3/+3
| | | | | | | | | And also fix all properties/signals/non-docs that were incorrect. Testing Done: Built docs and found no new warnings. Checked some docs for newly-available property/signal docs. Reviewed at https://reviews.imfreedom.org/r/1568/
* Convert PidginAccountsEnabledMenu from a menu controller to a GMenuModelGary Kramlich2022-07-281-3/+3
| | | | | | | Testing Done: Enabled and disabled a bunch of accounts from the menus while running under valgrind. Reviewed at https://reviews.imfreedom.org/r/1527/
* Update pidgin for the purple_account_manager_get_(in)active deprecationsGary Kramlich2022-07-211-1/+1
| | | | | | | Testing Done: Compiled and made sure the menus still functioned as expected. Reviewed at https://reviews.imfreedom.org/r/1536/
* Rename PidginInactiveAccountsMenu to PidginAccountsDisabledMenu to match ↵Gary Kramlich2022-07-211-4/+4
| | | | | | | | | | PidginAccountsEnabledMenu Testing Done: Ran and toggled a bunch of accounts from the menu. Built the docs and pot file as well. Reviewed at https://reviews.imfreedom.org/r/1528/
* Implement the UI for the new Notifications API.Gary Kramlich2022-07-041-0/+22
| | | | | | | | | | | | | | This currently only shows connection error notifications which have to be removed manually since an account with a connection error can not currently reconnect successfully. Testing Done: I used a IRC account with an server name that was unresolvable as well as an XMPP account with a wrong password to cause a fatal connection errors. I also used a IRC account connecting to a local instance of ZNC where I terminated ZNC to cause a server side connection failure. Bugs closed: PIDGIN-17634 Reviewed at https://reviews.imfreedom.org/r/1512/
* Remove the manager, editor, and substatus editor from gtksavedstatusesGary Kramlich2022-05-301-1/+3
| | | | | | | | | | | This code previously replaced via the new PidginStatusManager and PidginStatusEditor widgets, while substatuses were skipped as we determine their future. Testing Done: Ran and opened all the status dialogs and menus and stuff. Reviewed at https://reviews.imfreedom.org/r/1437/
* Convert plugin actions to GMenu and GActionGary Kramlich2022-05-271-0/+7
| | | | | | | | | Also ported the idle maker plugin to the new api. Testing Done: Made sure all of the actions for the idle maker plugin worked. Reviewed at https://reviews.imfreedom.org/r/1408/
* Update purple_core_init to take a PurpleUiInfo instanceGary Kramlich2022-05-201-1/+6
| | | | | | | | | Added an `id` property to `PurpleUiInfo` Testing Done: Ran the unit tests and verified I could run Pidgin and connect an account. Reviewed at https://reviews.imfreedom.org/r/1456/
* Remove the ui parameter from purple_account_[gs]et_enabledGary Kramlich2022-05-201-4/+4
| | | | | | | Testing Done: Enabled and disabled the demo account a bunch of times, including restarts, and the like. Reviewed at https://reviews.imfreedom.org/r/1458/
* Chain up to the parent class's implementation of the window_added default ↵Gary Kramlich2022-05-031-0/+3
| | | | | | | | | signal handler Testing Done: Tested again /r/1408 to make sure it was working. Reviewed at https://reviews.imfreedom.org/r/1412/
* Make PidginApplication manage action groups for all windowsGary Kramlich2022-05-031-0/+71
| | | | | | | Testing Done: Compiled only. Reviewed at https://reviews.imfreedom.org/r/1411/
* The debug command line option does not actually take an argument.Stu Tomlinson2022-04-271-16/+4
| | | | | | | | | | | | | | Muscle memory from 10+ years ago had me launch pidgin with options '-dn', but this fails with an error: $ ./build/pidgin/pidgin3 -dn Missing argument for -d Testing Done: Launch with -d - see debug output and enabled accounts log in Launch without -d - see no debug output (after realising DEBUG also needed to be undefined) and enabled accounts log in Launch with -dn - see debug outout and no accounts log in Reviewed at https://reviews.imfreedom.org/r/1393/
* Overhaul the status boxGary Kramlich2022-04-041-2/+14
| | | | | | | | | | | | | | | | | | | | | | | * Subclass GtkBox instead of GtkContainer * Remove message editing * Use a GtkComboBox instead of our fake GtkComboBox * Move to item id's rather than indexes * Moved new status, and saved status to GActions * Removed the account and token_account properties. we now show primitives and saved status * Removed the ability to delete saved status from the widget * Use a widget template to construct the ui elements * Removed the connection detection stuff Testing Done: Verified status were updated when used in the saved status manager. Verified that the new status and saved status actions work. Verified that the primitive status work. Verified that the saved statuses work. Bugs closed: PIDGIN-17591 Reviewed at https://reviews.imfreedom.org/r/1312/
* Replace PidginAccountsDisabledMenu with PidginInactiveAccountsMenu which is ↵Gary Kramlich2022-03-251-5/+6
| | | | | | | | | | | | | | a GMenuModel subclass. This gives us a bit more control as we are always in control of the attributes, so we don't need to modify the menu in place. This also made it trivial to add the protocol icons which are very helpful when you have the same user name on multiple protocols. Testing Done: Enabled and disabled two accounts a lot while under valgrind. Reviewed at https://reviews.imfreedom.org/r/1366/
* Replace PURPLE_CALLBACK by G_CALLBACKElliott Sales de Andrade2022-03-251-4/+4
| | | | | | | | | Another straight search-and-replace for 'easy' review. Testing Done: Compile only. Reviewed at https://reviews.imfreedom.org/r/1371/
* Create a new PidginAccountManager that replaces the manually built one.Gary Kramlich2022-03-221-2/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | The old code was left to keep this change as clean as possible and will be removed afterwards. Drag and drop as been removed as it's completely different in GTK4 and I didn't want to waste time on it since it's going to be deleted when it's rewritten. I also didn't implement the double click to modify account as that's different in GTK4 and we don't yet have new Event Controller for it in GTK3. Support for selecting multiple accounts was dropped and now only one account may be selected at a time. Finally, I changed the title of the "Delete" button to "Remove" as "Remove" seems more clear. Testing Done: Used the previous dialog to add, remove, and modify accounts and verified they were updated appropriately. Also started pidgin without any accounts enabled, to verify that the new dialog was shown instead of the old. Tested the add, modify, remove, and close buttons. Tested that the modify and remove buttons are only sensitive when an account is selected. Bugs closed: PIDGIN-17589 Reviewed at https://reviews.imfreedom.org/r/1318/
* Move the singleton handling of the about dialog to the action handler.Gary Kramlich2022-03-211-5/+5
| | | | | | | Testing Done: Ran and made sure a second dialog wasn't created when opening the dialog with one already opened. Reviewed at https://reviews.imfreedom.org/r/1359/
* Create a new status manager that's built in gladeGary Kramlich2022-03-211-2/+9
| | | | | | | | | | | | | | | | | | | | | | Behavorial Changes: * Confirmation dialog for remove has been removed. * Remove button is disabled if the currently selected status is the active status. Previously this scenario was silently ignored after confirmation. Errata: It is possible to open multiple modify windows for a status. Previously the editor was reaching into the manager and controlling this pointer. I was going to fix this, but the editor isn't a widget yet and I don't like doing duplicate work. Testing Done: Basically tried everything I could think of with editing and selecting and so on. Bugs closed: PIDGIN-17590 Reviewed at https://reviews.imfreedom.org/r/1322/
* Add a menu controller for the accounts enabled section of the accounts menuGary Kramlich2022-03-181-3/+56
| | | | | | | Testing Done: Ran and verified the menu items worked. Reviewed at https://reviews.imfreedom.org/r/1344/
* Fix a type warning in new dynamic menuElliott Sales de Andrade2022-03-171-2/+2
| | | | | | | Testing Done: Compiled with one less warning. Reviewed at https://reviews.imfreedom.org/r/1355/
* Create a menu controller that will keep a GMenu in sync with the disabled ↵Gary Kramlich2022-03-141-0/+40
| | | | | | | | | accounts in libpurple Testing Done: Used the account manager to disable and account, then disabled it from the menu and verified that the item was removed. Reviewed at https://reviews.imfreedom.org/r/1326/
* Stop reaching into the PidginBuddyList struct from other filesGary Kramlich2022-01-131-3/+4
| | | | | | | Testing Done: Compiled Reviewed at https://reviews.imfreedom.org/r/1220/
* Add a statuses item to the tools menu that opens the status managerGary Kramlich2022-01-031-0/+11
| | | | | | | | Testing Done: Verified the menu item works Verified that opening the dialog from the status widget just focuses the dialog. Reviewed at https://reviews.imfreedom.org/r/1217/
* port Pidgin to the new PurpleAccountManager apiGary Kramlich2021-12-141-1/+4
| | | | | | | Testing Done: Compiled and ran locally, everything seemed to be okay. Reviewed at https://reviews.imfreedom.org/r/1149/