[rygel/config] Skeleton for handling of dialog response.
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: svn-commits-list gnome org
- Subject: [rygel/config] Skeleton for handling of dialog response.
- Date: Tue, 21 Apr 2009 12:49:13 -0400 (EDT)
commit 17ff1f4ff171671cf1e63a2acebed92cdff5da16
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Sun Apr 19 17:52:24 2009 +0300
Skeleton for handling of dialog response.
---
src/ui/rygel-preferences.vala | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
diff --git a/src/ui/rygel-preferences.vala b/src/ui/rygel-preferences.vala
index 8c84da8..dd244e2 100644
--- a/src/ui/rygel-preferences.vala
+++ b/src/ui/rygel-preferences.vala
@@ -30,9 +30,22 @@ public class Rygel.Preferences : Dialog {
this.add_button (STOCK_APPLY, ResponseType.APPLY);
this.add_button (STOCK_CANCEL, ResponseType.REJECT);
+ this.response += this.on_response;
+
this.show_all ();
}
+ private void on_response (Preferences pref, int response_id) {
+ switch (response_id) {
+ case ResponseType.REJECT:
+ case ResponseType.ACCEPT:
+ Gtk.main_quit ();
+ break;
+ case ResponseType.APPLY:
+ break;
+ }
+ }
+
public new void run () {
Gtk.main ();
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]