Merge lp:~eduardo-mucelli/cairo-dock-plug-ins/DbusInterfaces into lp:~cairo-dock-team/cairo-dock-plug-ins/plug-ins

Proposed by Eduardo Mucelli Rezende Oliveira
Status: Merged
Merged at revision: 1870
Proposed branch: lp:~eduardo-mucelli/cairo-dock-plug-ins/DbusInterfaces
Merge into: lp:~cairo-dock-team/cairo-dock-plug-ins/plug-ins
Diff against target: 78 lines (+18/-5)
5 files modified
Dbus/interfaces/bash/CDBashApplet.sh (+1/-0)
Dbus/interfaces/mono/CDApplet.cs (+9/-5)
Dbus/interfaces/python/CDApplet.py (+2/-0)
Dbus/interfaces/ruby/CDApplet.rb (+2/-0)
Dbus/interfaces/vala/CDApplet.vala (+4/-0)
To merge this branch: bzr merge lp:~eduardo-mucelli/cairo-dock-plug-ins/DbusInterfaces
Reviewer Review Type Date Requested Status
Cairo-Dock Devs Pending
Review via email: mp+50660@code.launchpad.net

Description of the change

Dbus interfaces. Defining a constant to MAIN_MENU_ID instead of keep using the '0', and commenting what that means when building the menus

To post a comment you must log in.
1870. By Eduardo Mucelli Rezende Oliveira

Defining a constant to MAIN_MENU_ID instead of keep using the '0', and commenting what that means when building the menus

Revision history for this message
Matthieu Baerts (matttbe) wrote :

@Eduardo: Thank you for this modification!

Just one tiny thing for your next commit: is it possible to use some tabulations instead of a lot of spaces just because we use this layout everywhere in the source code :)

Revision history for this message
Eduardo Mucelli Rezende Oliveira (eduardo-mucelli) wrote :

@Matttbe: Sure. I'm also confused because in Python I change the editor to use Tab, and in Ruby I change to spaces, but sometimes I forget.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'Dbus/interfaces/bash/CDBashApplet.sh'
2--- Dbus/interfaces/bash/CDBashApplet.sh 2011-02-12 03:01:04 +0000
3+++ Dbus/interfaces/bash/CDBashApplet.sh 2011-02-21 21:55:00 +0000
4@@ -46,6 +46,7 @@
5 MENU_SEPARATOR=2
6 MENU_CHECKBOX=3
7 MENU_RADIO_BUTTON=4
8+MAIN_MENU_ID=0
9
10 call() { # method, args
11 method=$1
12
13=== modified file 'Dbus/interfaces/mono/CDApplet.cs'
14--- Dbus/interfaces/mono/CDApplet.cs 2011-02-12 03:01:04 +0000
15+++ Dbus/interfaces/mono/CDApplet.cs 2011-02-21 21:55:00 +0000
16@@ -63,12 +63,16 @@
17 MIDDLE
18 }
19 public enum MenuItemType {
20- MENU_ENTRY = 0,
21- MENU_SUB_MENU,
22- MENU_SEPARATOR,
23- MENU_CHECKBOX,
24- MENU_RADIO_BUTTON
25+ MENU_ENTRY = 0,
26+ MENU_SUB_MENU,
27+ MENU_SEPARATOR,
28+ MENU_CHECKBOX,
29+ MENU_RADIO_BUTTON
30 }
31+
32+ public enum MenuItemId {
33+ MAIN_MENU_ID = 0
34+ }
35
36 public CDApplet()
37 {
38
39=== modified file 'Dbus/interfaces/python/CDApplet.py'
40--- Dbus/interfaces/python/CDApplet.py 2011-01-18 01:03:52 +0000
41+++ Dbus/interfaces/python/CDApplet.py 2011-02-21 21:55:00 +0000
42@@ -53,6 +53,8 @@
43 MENU_SEPARATOR = 2
44 MENU_CHECKBOX = 3
45 MENU_RADIO_BUTTON = 4
46+
47+ MAIN_MENU_ID = 0
48
49 def __init__(self):
50 """ initialize the applet. Must be called by any class that inheritates from it.
51
52=== modified file 'Dbus/interfaces/ruby/CDApplet.rb'
53--- Dbus/interfaces/ruby/CDApplet.rb 2011-02-17 00:03:58 +0000
54+++ Dbus/interfaces/ruby/CDApplet.rb 2011-02-21 21:55:00 +0000
55@@ -47,6 +47,8 @@
56 MENU_CHECKBOX = 3
57 MENU_RADIO_BUTTON = 4
58
59+ MAIN_MENU_ID = 0
60+
61 def initialize
62 #~ self.cAppletName = File.basename(Dir.getwd)
63 #~ self.cConfFile = File.expand_path("~/.config/cairo-dock/current_theme/plug-ins/#{self.cAppletName}/#{self.cAppletName}.conf")
64
65=== modified file 'Dbus/interfaces/vala/CDApplet.vala'
66--- Dbus/interfaces/vala/CDApplet.vala 2011-01-18 01:03:52 +0000
67+++ Dbus/interfaces/vala/CDApplet.vala 2011-02-21 21:55:00 +0000
68@@ -111,6 +111,10 @@
69 MENU_RADIO_BUTTON
70 }
71
72+ public enum MenuItemId {
73+ MAIN_MENU_ID = 0
74+ }
75+
76 public CDApplet(string[] argv)
77 {
78 this.cAppletName = argv[0].substring(2,999);

Subscribers

People subscribed via source and target branches