From 84a27086bbd9f493128b354300f9c77ccb32a56b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sat, 18 Apr 2015 15:42:59 +0200 Subject: Imported Upstream version 0.6.0 --- src/actionGroups/actionGroup.vala | 68 +++++++++++++++++++-------------------- 1 file changed, 34 insertions(+), 34 deletions(-) (limited to 'src/actionGroups/actionGroup.vala') diff --git a/src/actionGroups/actionGroup.vala b/src/actionGroups/actionGroup.vala index c54be2f..8bbcde4 100644 --- a/src/actionGroups/actionGroup.vala +++ b/src/actionGroups/actionGroup.vala @@ -1,23 +1,23 @@ -/* -Copyright (c) 2011 by Simon Schneegans - -This program is free software: you can redistribute it and/or modify it -under the terms of the GNU General Public License as published by the Free -Software Foundation, either version 3 of the License, or (at your option) -any later version. - -This program is distributed in the hope that it will be useful, but WITHOUT -ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for -more details. - -You should have received a copy of the GNU General Public License along with -this program. If not, see . -*/ +///////////////////////////////////////////////////////////////////////// +// Copyright (c) 2011-2015 by Simon Schneegans +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation, either version 3 of the License, or (at +// your option) any later version. +// +// This program is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +// General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program. If not, see . +///////////////////////////////////////////////////////////////////////// namespace GnomePie { -///////////////////////////////////////////////////////////////////////// +///////////////////////////////////////////////////////////////////////// // A base class storing a set of Actions. Derived classes may define // how these Actions are created. This base class serves for custom // actions, defined by the user. @@ -28,67 +28,67 @@ public class ActionGroup : GLib.Object { ///////////////////////////////////////////////////////////////////// /// A list of all stored actions. ///////////////////////////////////////////////////////////////////// - + public Gee.ArrayList actions { get; private set; } - + ///////////////////////////////////////////////////////////////////// /// The ID of the pie to which this group is attached. ///////////////////////////////////////////////////////////////////// - + public string parent_id { get; construct set; } - + ///////////////////////////////////////////////////////////////////// /// C'tor, initializes all members. ///////////////////////////////////////////////////////////////////// - + public ActionGroup(string parent_id) { GLib.Object(parent_id : parent_id); } - + construct { this.actions = new Gee.ArrayList(); } - + ///////////////////////////////////////////////////////////////////// /// This one is called, when the ActionGroup is deleted. ///////////////////////////////////////////////////////////////////// - + public virtual void on_remove() {} - + ///////////////////////////////////////////////////////////////////// /// Adds a new Action to the group. ///////////////////////////////////////////////////////////////////// - + public void add_action(Action new_action) { this.actions.add(new_action); } - + ///////////////////////////////////////////////////////////////////// /// Removes all Actions from the group. ///////////////////////////////////////////////////////////////////// - + public void delete_all() { actions.clear(); } - + ///////////////////////////////////////////////////////////////////// /// Makes all contained Slices no Quick Actions. ///////////////////////////////////////////////////////////////////// - + public void disable_quickactions() { foreach (var action in actions) action.is_quickaction = false; } - + ///////////////////////////////////////////////////////////////////// /// Returns true, if one o the contained Slices is a Quick Action ///////////////////////////////////////////////////////////////////// - + public bool has_quickaction() { foreach (var action in actions) if (action.is_quickaction) return true; - + return false; } } -- cgit v1.2.3