Commit graph

62 commits

Author SHA1 Message Date
Georges Basile Stavracas Neto
1e580c679b online-accounts: Add an offline message label
When offline, we currently block the new accounts listbox
so that users can't add new accounts. There is, however,
no visual indication that we're offline, besides the listbox.

Fix that by adding a descriptive label that's only visible
when offline.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-02-22 23:00:49 -03:00
Georges Basile Stavracas Neto
e9198bdb4d online-accounts: Add a bottom row to display non-branded providers
As per the mockups, and mimicking the dialog behavior, add a bottom
row that shows non-branded providers.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-02-22 23:00:49 -03:00
Georges Basile Stavracas Neto
13da84e451 online-accounts: Add margins to the rows' icons
Per Allan's request, add more margin to the rows' icons.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-02-17 17:23:59 +01:00
Georges Basile Stavracas Neto
1f1f2e2b1f online-accounts: Always keep editor dialog size the minimum
When adding and editing accounts, the different options that Online
Accounts provides may require different sizes of the dialog. There is,
however, a specific issue where the dialog can't resize because a
provider widget is interefering with the others.

Fix that by making the dialog's stack non-homogeneous, and making sure
to always reset the dialog size before showing it.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-02-17 17:19:45 +01:00
Georges Basile Stavracas Neto
6c633621a4 online-accounts: Drop GoaAddAccountDialog
The dialog is not used anymore, and can be safely removed.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-02-13 16:00:53 +01:00
Georges Basile Stavracas Neto
a6858fff62 online-accounts: Hide remove button when account is locked
https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-02-13 15:09:26 +01:00
Georges Basile Stavracas Neto
5807bb4cc3 online-accounts: Add separators between listbox rows
https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-02-13 14:59:14 +01:00
Georges Basile Stavracas Neto
14d0988208 online-accounts: Bring back account removal
Following the previous commit, this commit effectively brings
back the account removal feature that was temporarily removed
by 4e197b491f.

This is now reimplemented as an in-app notification, and users
now have the option to undo an accidentally removed account.

Some changes by Debarshi Ray.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-02-13 14:37:08 +01:00
Georges Basile Stavracas Neto
d50a07da56 online-accounts: Make adding an account inline to the edit dialog
When adding an account, the old proccess was: use the (removed) toolbar
to open the New Account dialog, select a provider in that dialog, add
the account and see the newly created account in the panel itself.

That approach had issues, e.g. the user would have to close the dialog
if she mistakenly selected a provider. After moving the provider list
to the panel itself, it doesn't make sense anymore to have another
provider list inside the dialog.

Fix this by moving the new account view to the accounts dialog.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-02-08 17:33:46 +01:00
Georges Basile Stavracas Neto
6f60e64075 online-accounts: Fix typo
This was introduced while rebasing
c26f8ae018

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-02-08 16:26:09 +01:00
Georges Basile Stavracas Neto
76062e1106 online-accounts: Add a stack to the account dialog
This will be used to unify the account creation proccess and the
account editor.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-01-03 18:50:23 +01:00
Georges Basile Stavracas Neto
dce3e168d2 online-accounts: Remove unused widgets
These widgets are not used anymore, and they're not present in the
latest designs.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-01-03 18:36:41 +01:00
Georges Basile Stavracas Neto
c26f8ae018 online-accounts: Add a providers listbox to the panel
This commit starts moving the contents of the add account dialog
class to the panel itself, by adding a providers listbox below
the list of available account as per the new mockups. As a side effect,
this commit temporarily makes removing an account non-functional.

The next commits are focused on finishing this move and removing
the add account dialog.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2017-01-03 17:52:07 +01:00
Georges Basile Stavracas Neto
4e197b491f online-accounts: Make the main listbox non-selectable
Instead of selecting an account, this commit makes the account
editor dialog only visible through explicit activation of the
account row.

As a side effect, this commit temporarily makes removing an
account non-functional.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2016-12-15 19:40:28 +01:00
Debarshi Ray
182cac1ea3 online-accounts: Update the UI if IsLocked changes
We want to check the IsLocked property whenever we call
show_page_account. ie. when we show an account for the first time, and
also when the displayed account emits account-changed. Hence it is
better to have them together.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2016-12-15 19:08:47 +01:00
Georges Basile Stavracas Neto
1a427a8ac3 online-accounts: Use a dialog to manage the online account
Following the mockups, the Online Accounts panel shall use a modal
dialog to edit online accounts.

This commit moves the current widgets to a dialog, and shows this
dialog whenever an account is selected.

Some changes by Debarshi Ray.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2016-12-15 17:51:59 +01:00
Georges Basile Stavracas Neto
54df308648 online-accounts: Use the ui file to connect to signals
Simplify the code by using the GtkBuilder file to connect to the
signals instead of manually doing it in the code.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2016-11-30 17:23:10 +01:00
Georges Basile Stavracas Neto
bdde40ac15 online-accounts: Use a listbox instead of a treeview
As part of the port to the redesigned Online Accounts panel,
the main widget to be displayed is a GtkListBox, so we can have
finer control of the UI elements and eventually be able to put
real widgets instead of using cell renderers.

This commit, then, makes the Online Account panel use a listbox
widget in the sidebar. The behavior of the panel was not changed.

Since its using a listbox now, we can drop the custom GoaPanelAccountsModel
class.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2016-11-30 17:16:35 +01:00
Georges Basile Stavracas Neto
902ab4e448 online-accounts: Turn into a template class
https://bugzilla.gnome.org/show_bug.cgi?id=774222
2016-11-30 17:16:35 +01:00
Georges Basile Stavracas Neto
e5208a397a online-accounts: Remove unnecessary code
Calling gtk_style_context_set_junction_sides makes no visual
difference. We are using stock GTK+ containers, which should already
be taking care of this.

https://bugzilla.gnome.org/show_bug.cgi?id=774222
2016-11-30 17:16:35 +01:00
Georges Basile Stavracas Neto
013b2d865b online-accounts: Use G_DECLARE_FINAL_TYPE
https://bugzilla.gnome.org/show_bug.cgi?id=774222
2016-11-30 17:16:35 +01:00
Debarshi Ray
2cb0f5e3a3 online-accounts: Let goa_provider_show_account create the full UI
It is not ideal to have the UI split across a semi-stable,
cross-module interface boundary. Non-trivial changes to the UI require
changes to the goa_provider_show_account interface. In fact, we were
already not using it the way it was originally intended to be.
Moreover, it prevents us from having a sufficiently different UI for
certain account types.

Instead, let's just pass a vertical GtkBox to the GoaProvider and let
it fill it up whichever way it wants to.

Bump required GOA version for the new goa_provider_show_account
behaviour.

https://bugzilla.gnome.org/show_bug.cgi?id=769213
2016-08-14 12:18:52 +02:00
Christophe Fergeau
c84722248e shell: Revert "Let panels have their own commandline flags"
This reverts commit 31a8a99440.

This was meant for bgo#695885 which has stalled for a while, so this
feature has no in-tree user. This commit removes it for now, this can be
readded when users for it materialize.

https://bugzilla.gnome.org/show_bug.cgi?id=751597
2015-07-16 11:49:34 +02:00
Bastien Nocera
cff4336032 online-accounts: Prevent the attention-needed icon from getting hidden
By making sure that the label inside each of the list items gets
only whatever space is left by the left and right-side icons.

https://bugzilla.gnome.org/show_bug.cgi?id=746538
2015-04-13 15:05:40 +02:00
Debarshi Ray
b24bfa8197 online-accounts: Disable the remove button for locked accounts
Bump required GOA version for the IsLocked property.

https://bugzilla.gnome.org/show_bug.cgi?id=737665
2015-04-13 14:19:59 +02:00
Rui Matos
54227dc21e online-accounts: Fix deprecated API usage
https://bugzilla.gnome.org/show_bug.cgi?id=740986
2014-12-05 16:13:29 +01:00
Daniel Mustieles
2c5951819d Updated FSF's address 2014-01-29 11:27:38 +01:00
Rui Matos
9288bbbffc online-accounts: Remove unused toplevel window from .ui file
https://bugzilla.gnome.org/show_bug.cgi?id=708286
2013-10-01 10:05:03 +02:00
Debarshi Ray
15b4c7a1bb online-accounts: Fix the use of GtkGrids for showing an account
This has the nice side-effect that rows in the different grids can no
longer get misaligned.

https://bugzilla.gnome.org/show_bug.cgi?id=706645
2013-08-23 16:19:51 +02:00
Marco Barisione
82e6777cb1 online-accounts: use the async function to get all the providers
https://bugzilla.gnome.org/show_bug.cgi?id=706148
2013-08-22 15:27:40 +01:00
Yosef Or Boczko
a9f6f69f70 online-accounts: drop GtkStock
https://bugzilla.gnome.org/show_bug.cgi?id=704178
2013-07-19 15:57:12 +03:00
Emanuele Aina
8762e2f8dc online-accounts: Accept requests for account creation on DBus/cmdline
Also accepts additional data to pre-seed the GOA dialog, in particular
the provider name (eg. 'google') and provider-specific data encoded in a
a GVariant dict ('a{sv}') to eg. pass cookies from an existing web
session (this is only available from DBus activation).

It can be run from the command line as:
 $ gnome-control-center online-accounts add google

https://bugzilla.gnome.org/show_bug.cgi?id=694315
2013-04-23 18:32:59 +02:00
Emanuele Aina
31a8a99440 shell: Let panels have their own commandline flags
Add a class method to CcPanel to get a GOptionGroup which will be added
to the main commandline parser. This gives panels the chance to have
commandline "--flags" in addition to the already available parameters.

This changes changes the way parameters are passed to panels: the first
entry in the GVariant array is always the a{sv} dictionary of
commandline flags, followed by the remaining free-form arguments.

https://bugzilla.gnome.org/show_bug.cgi?id=696054
2013-04-03 18:09:11 +02:00
Emanuele Aina
9977bb200e shell: Use GVariant to convey panel arguments instead of a string array
By using a GVariant of type "av" we can potentially pass more structured
data to panels, which will become relevant with the ability to invoke
them by GAction-based DBus-activation introduced in the following patch.

https://bugzilla.gnome.org/show_bug.cgi?id=696054
2013-04-03 18:02:10 +02:00
Emanuele Aina
397181e5d2 online-accounts: Small cleanup about resource releasing
Use g_clear_object() as a NULL-safe g_object_unref() and
g_list_free_full() instead of explicitly iterating the list contents.

https://bugzilla.gnome.org/show_bug.cgi?id=695877
2013-04-03 16:05:17 +02:00
Debarshi Ray
48a9df92c3 online-accounts: Scroll the tree view when showing an account
https://bugzilla.gnome.org/show_bug.cgi?id=695171
2013-03-19 14:24:31 +01:00
Debarshi Ray
271ae25c3a online-accounts: Colours of symbolics should match the text
https://bugzilla.gnome.org/show_bug.cgi?id=695171
2013-03-05 11:21:56 +01:00
Ebru Akagunduz
f2818405ab online-accounts: Nicer error states
https://bugzilla.gnome.org/show_bug.cgi?id=689645
2013-02-27 17:27:34 +01:00
Debarshi Ray
d58d426d34 online-accounts: Use g_warning instead of goa_warning
goa_warning is meant for goa-daemon, and it does not really add any
value in this case. Switching to g_warning lets us cut down on the
number of symbols that are exported from libgoabackend.

https://bugzilla.gnome.org/show_bug.cgi?id=693261
2013-02-07 12:59:00 +01:00
Debarshi Ray
6b0ec0038c online-accounts: #include the resource header
This is a fallout from 0653773ed8.
2013-01-23 15:12:28 +01:00
Cosimo Cecchi
0653773ed8 online-accounts: use a GResource for GtkBuilder UI definition
https://bugzilla.gnome.org/show_bug.cgi?id=691132
2013-01-07 10:57:06 +01:00
Bastien Nocera
3686cf7eb8 shell: Make all control-center plugins static
This makes loading faster, with less I/O, avoids unnecessary
code duplication (around 1k lines shaved), and ensures that
all the panels link and work appropriately.

By the same token, it will stop external panels from being
created, and loaded.

https://bugzilla.gnome.org/show_bug.cgi?id=690036
2012-12-11 17:07:39 +01:00
Ebru Akagunduz
c5fbe9a396 online-accounts: Disable adding accounts when network unavailable
Fixes: https://bugzilla.gnome.org/678161
2012-12-04 14:25:28 +01:00
Ebru Akagunduz
ff186736dc online-accounts: Bind "accounts-button-add" to network availability
Fixes: https://bugzilla.gnome.org/678161
2012-12-03 13:14:34 +01:00
Bastien Nocera
4a993e753a online-accounts: Remove unneeded signal disconnections
Those signals will not be emitted anymore, as the objects that
could emit them will be destroyed.

Fixes a warning on exit, as panel->accounts_treeview is already
destroyed when we get there.

https://bugzilla.gnome.org/show_bug.cgi?id=684702
2012-09-25 11:31:36 +02:00
Ray Strode
b0e7a5efa8 panels: add register macro
Bastien says he doesn't like the blank class_finalize
functions in every panel and he would like a wrapper
macro to hide them.

This commit does that.
2012-08-21 14:32:33 -04:00
Ray Strode
3bf8bcf3f8 online-accounts: set up finalize handler at class init time
It was being set up at class finalization time, which is too late.

Fixes crash when switching from panel to shell and back
(and then try to interact with the switches).

https://bugzilla.gnome.org/show_bug.cgi?id=682379
2012-08-21 13:37:54 -04:00
Debarshi Ray
06ede122ab online-accounts: Don't show spurious "No online accounts configured"
Programmatically deleting or inserting a row into a GtkTreeModel
implementation does not change the selection on the GtkTreeView even
if it is in browse mode (see GTK+ documentation). So, we need to
connect to the model's row-deleted and row-inserted signals and adjust
the selection ourselves.

Fixes: https://bugzilla.gnome.org/682175
2012-08-21 19:17:30 +02:00
Matthew Barnes
7dd80f829f online-accounts: Open specific account through command-line
Bump required GOA version to 3.5.90 for goa_client_lookup_by_id.

Fixes: https://bugzilla.gnome.org/680458
2012-08-18 20:19:15 +01:00
Debarshi Ray
8138227ae3 online-accounts: Improve the layout when there is no configured account
Use a GtkButton instead of a GtkLabel to incite the user to configure
a new account, and insensitize the GtkBox on the left.

Fixes: https://bugzilla.gnome.org/672421
2012-06-25 16:18:39 +02:00