~ubuntu-branches/ubuntu/trusty/eiciel/trusty-proposed

« back to all changes in this revision

Viewing changes to src/eiciel_main_controller.hpp

  • Committer: Bazaar Package Importer
  • Author(s): Michael Biebl
  • Date: 2010-06-04 02:38:02 UTC
  • mfrom: (1.2.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20100604023802-jp2v6c9uviiioc5z
* New upstream release.
* debian/patches/02-gio.patch
  - Removed, merged upstream.
* debian/patches/03-no-libgnomeui.patch
  - Removed, merged upstream.
* debian/patches/01-fix-gettext-translations.patch
  - Fix gettext translations by using dgettext and specifying the correct
    domainname.
* debian/patches/02-de-po.patch
  - Update and complete German translation.
* debian/rules
  - Remove de.gmo on clean and rebuild it on build.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
    Eiciel - GNOME editor of ACL file permissions.
 
3
    Copyright (C) 2004-2010 Roger Ferrer Ib��ez
 
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 as published by
 
7
    the Free Software Foundation; either version 2 of the License, or
 
8
    (at your option) any later version.
 
9
 
 
10
    This program is distributed in the hope that it will be useful,
 
11
    but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
13
    GNU General Public License for more details.
 
14
 
 
15
    You should have received a copy of the GNU General Public License
 
16
    along with this program; if not, write to the Free Software
 
17
    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301,  USA
 
18
*/
 
19
#ifndef EICIEL_MAIN_CONTROLER_HPP
 
20
#define EICIEL_MAIN_CONTROLER_HPP
 
21
 
 
22
#include <config.hpp>
 
23
#include <set>
 
24
#include "eiciel_main_window.hpp"
 
25
#include "acl_manager.hpp"
 
26
#include "acl_element_kind.hpp"
 
27
#include <gettext.h>
 
28
 
 
29
using namespace std;
 
30
 
 
31
class EicielWindow;
 
32
 
 
33
class EicielMainController : public sigc::trackable
 
34
{
 
35
        private:
 
36
                ACLManager* _ACL_manager;
 
37
                EicielWindow* _window;
 
38
        set<string> _users_list;
 
39
        set<string> _groups_list;
 
40
                bool _is_file_opened;
 
41
                bool _updating_window;
 
42
                Glib::ustring _last_error_message;
 
43
 
 
44
                bool _list_must_be_updated;
 
45
                bool _show_system;
 
46
 
 
47
                void update_acl_list();
 
48
                void update_acl_entry(ElementKind e, string nom, 
 
49
                                bool lectura, bool escriptura, bool execucio);
 
50
                void remove_acl(string nomEntrada, ElementKind e);
 
51
                void add_acl_entry(string s, ElementKind e, bool esDefault);
 
52
                void change_default_acl();
 
53
 
 
54
                void fill_lists();
 
55
                void show_system_participants(bool b);
 
56
                void check_editable();
 
57
 
 
58
        set<string> get_users_list();
 
59
        set<string> get_groups_list();
 
60
 
 
61
        bool is_directory();
 
62
        public:
 
63
                void open_file(string s);
 
64
                Glib::ustring last_error();
 
65
                bool opened_file();
 
66
                friend class EicielWindow; 
 
67
                EicielMainController();
 
68
                ~EicielMainController();
 
69
};
 
70
 
 
71
#endif