aboutsummaryrefslogtreecommitdiff
path: root/data/main.vala
diff options
context:
space:
mode:
authorWilliam Hua <william.hua@canonical.com>2013-06-21 13:56:38 -0400
committerWilliam Hua <william.hua@canonical.com>2013-06-21 13:56:38 -0400
commitb7c785a8f7b5c071c6a55419286cb24d19735331 (patch)
tree2cf96ac1f76c17f6102dd48f0b224c47345d3723 /data/main.vala
parent9d174c31bda88ec1abe97f20f34a62928c920d71 (diff)
downloadayatana-indicator-keyboard-b7c785a8f7b5c071c6a55419286cb24d19735331.tar.gz
ayatana-indicator-keyboard-b7c785a8f7b5c071c6a55419286cb24d19735331.tar.bz2
ayatana-indicator-keyboard-b7c785a8f7b5c071c6a55419286cb24d19735331.zip
Simplify abbreviations.
Diffstat (limited to 'data/main.vala')
-rw-r--r--data/main.vala11
1 files changed, 3 insertions, 8 deletions
diff --git a/data/main.vala b/data/main.vala
index 9be80ebf..dec6e6cf 100644
--- a/data/main.vala
+++ b/data/main.vala
@@ -72,16 +72,11 @@ int main (string[] args) {
var occurrences = new Gee.HashMap <string, int> ();
layouts.foreach ((name) => {
- string display;
- string layout;
+ string short_name;
- info.get_layout_info (name, out display, null, out layout, null);
+ info.get_layout_info (name, null, out short_name, null, null);
- if (display == null) {
- display = get_display_name (layout);
- }
-
- var abbreviation = get_abbreviation (display);
+ var abbreviation = get_abbreviation (short_name);
if (!occurrences.has_key (abbreviation)) {
occurrences[abbreviation] = 1;