702.3.1
by Michael Terry
add modelines and fix up some inconsistent tabbings |
1 |
// -*- Mode: C++; indent-tabs-mode: nil; tab-width: 2 -*-
|
572.1.11
by Neil Jagdish Patel
Import the work done so far with Compiz |
2 |
/*
|
3 |
* Copyright (C) 2010 Canonical Ltd
|
|
4 |
*
|
|
5 |
* This program is free software: you can redistribute it and/or modify
|
|
6 |
* it under the terms of the GNU General Public License version 3 as
|
|
7 |
* published by the Free Software Foundation.
|
|
8 |
*
|
|
9 |
* This program is distributed in the hope that it will be useful,
|
|
10 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
11 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
12 |
* GNU General Public License for more details.
|
|
13 |
*
|
|
14 |
* You should have received a copy of the GNU General Public License
|
|
15 |
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
16 |
*
|
|
17 |
* Authored by: Neil Jagdish Patel <neil.patel@canonical.com>
|
|
18 |
*/
|
|
19 |
||
20 |
#ifndef FAVORITE_STORE_GSETTINGS_H
|
|
21 |
#define FAVORITE_STORE_GSETTINGS_H
|
|
22 |
||
23 |
#include <gio/gio.h> |
|
24 |
||
25 |
#include "FavoriteStore.h" |
|
26 |
||
27 |
// An abstract object that facilitates getting and modifying the list of favorites
|
|
28 |
// Use GetDefault () to get the correct store for the session
|
|
29 |
||
30 |
class FavoriteStoreGSettings : public FavoriteStore |
|
31 |
{
|
|
32 |
public: |
|
33 |
||
572.1.19
by Neil Jagdish Patel
Testing and jays branch |
34 |
FavoriteStoreGSettings (); |
35 |
FavoriteStoreGSettings (GSettingsBackend *backend); |
|
572.1.11
by Neil Jagdish Patel
Import the work done so far with Compiz |
36 |
~FavoriteStoreGSettings (); |
37 |
||
38 |
//Methods
|
|
620.1.8
by Neil Jagdish Patel
Initial changed signal support |
39 |
GSList * GetFavorites (); |
40 |
void AddFavorite (const char *desktop_path, gint position); |
|
41 |
void RemoveFavorite (const char *desktop_path); |
|
42 |
void MoveFavorite (const char *desktop_path, gint position); |
|
679.5.10
by Jason Smith
save our re-ordering |
43 |
void SetFavorites (std::list<const char *> desktop_paths); |
620.1.8
by Neil Jagdish Patel
Initial changed signal support |
44 |
|
45 |
void Changed (const char *key); |
|
572.1.11
by Neil Jagdish Patel
Import the work done so far with Compiz |
46 |
|
47 |
private: |
|
620.1.8
by Neil Jagdish Patel
Initial changed signal support |
48 |
void Init (); |
572.1.11
by Neil Jagdish Patel
Import the work done so far with Compiz |
49 |
void Refresh (); |
50 |
||
51 |
GSList *m_favorites; |
|
52 |
GSettings *m_settings; |
|
620.1.8
by Neil Jagdish Patel
Initial changed signal support |
53 |
bool m_ignore_signals; |
572.1.11
by Neil Jagdish Patel
Import the work done so far with Compiz |
54 |
};
|
55 |
||
56 |
#endif // FAVORITE_STORE_GSETTINGS_H |