[gnote] Port xkeybinder to new Preferences
- From: Aurimas Äernius <aurimasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnote] Port xkeybinder to new Preferences
- Date: Mon, 27 Jun 2011 09:20:43 +0000 (UTC)
commit cd9df0a6cf9fcae918cd96c51d2dbf9f36d7f01d
Author: Aurimas Äernius <aurisc4 gmail com>
Date: Tue Jun 21 23:28:59 2011 +0300
Port xkeybinder to new Preferences
Use new Preferences API with Gio::Settings.
src/xkeybinder.cpp | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/src/xkeybinder.cpp b/src/xkeybinder.cpp
index f1998c3..818f3ce 100644
--- a/src/xkeybinder.cpp
+++ b/src/xkeybinder.cpp
@@ -1,6 +1,7 @@
/*
* gnote
*
+ * Copyright (C) 2011 Aurimas Cernius
* Copyright (C) 2009 Hubert Figuiere
*
* This program is free software: you can redistribute it and/or modify
@@ -70,14 +71,15 @@ namespace gnote {
}
- bool XKeybinder::get_accel_keys(const std::string & gconf_path, guint & keyval,
+ bool XKeybinder::get_accel_keys(const std::string & key, guint & keyval,
Gdk::ModifierType & mods)
{
keyval = 0;
mods = (Gdk::ModifierType)0;
try {
- std::string binding = Preferences::obj().get<std::string> (gconf_path);
+ std::string binding = Preferences::obj().get_schema_settings(
+ Preferences::SCHEMA_KEYBINDINGS)->get_string(key);
if (binding.empty() || binding == "disabled") {
return false;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]