ruby-libnotify 0.4.1.1 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (81) hide show
  1. data/CHANGELOG.rdoc +12 -0
  2. data/README.rdoc +5 -7
  3. data/doc/Notify/Notification.html +1123 -0
  4. data/doc/Notify.html +518 -0
  5. data/doc/created.rid +3 -1
  6. data/doc/ext/rnotify_c.html +52 -0
  7. data/doc/images/brick.png +0 -0
  8. data/doc/images/brick_link.png +0 -0
  9. data/doc/images/bug.png +0 -0
  10. data/doc/images/bullet_black.png +0 -0
  11. data/doc/images/bullet_toggle_minus.png +0 -0
  12. data/doc/images/bullet_toggle_plus.png +0 -0
  13. data/doc/images/date.png +0 -0
  14. data/doc/images/find.png +0 -0
  15. data/doc/images/loadingAnimation.gif +0 -0
  16. data/doc/images/macFFBgHack.png +0 -0
  17. data/doc/images/package.png +0 -0
  18. data/doc/images/page_green.png +0 -0
  19. data/doc/images/page_white_text.png +0 -0
  20. data/doc/images/page_white_width.png +0 -0
  21. data/doc/images/plugin.png +0 -0
  22. data/doc/images/ruby.png +0 -0
  23. data/doc/images/tag_green.png +0 -0
  24. data/doc/images/wrench.png +0 -0
  25. data/doc/images/wrench_orange.png +0 -0
  26. data/doc/images/zoom.png +0 -0
  27. data/doc/index.html +93 -17
  28. data/doc/js/darkfish.js +116 -0
  29. data/doc/js/jquery.js +32 -0
  30. data/doc/js/quicksearch.js +114 -0
  31. data/doc/js/thickbox-compressed.js +10 -0
  32. data/doc/lib/RNotify_rb.html +56 -0
  33. data/doc/rdoc.css +706 -0
  34. data/examples/action.rb +1 -1
  35. data/examples/base.rb +1 -5
  36. data/examples/icon.png +0 -0
  37. data/examples/info.rb +1 -1
  38. data/examples/markup.rb +1 -4
  39. data/examples/multi-actions.rb +1 -1
  40. data/examples/update.rb +1 -6
  41. data/examples/urgency.rb +3 -8
  42. data/examples/xy.rb +1 -6
  43. data/ext/extconf.rb +23 -34
  44. data/ext/rnotify.c +72 -145
  45. data/lib/RNotify.rb +1 -1
  46. metadata +33 -52
  47. data/doc/classes/Notify/Notification.html +0 -787
  48. data/doc/classes/Notify/Notification.src/M000007.html +0 -65
  49. data/doc/classes/Notify/Notification.src/M000008.html +0 -49
  50. data/doc/classes/Notify/Notification.src/M000009.html +0 -43
  51. data/doc/classes/Notify/Notification.src/M000010.html +0 -35
  52. data/doc/classes/Notify/Notification.src/M000011.html +0 -33
  53. data/doc/classes/Notify/Notification.src/M000012.html +0 -36
  54. data/doc/classes/Notify/Notification.src/M000013.html +0 -48
  55. data/doc/classes/Notify/Notification.src/M000014.html +0 -36
  56. data/doc/classes/Notify/Notification.src/M000015.html +0 -38
  57. data/doc/classes/Notify/Notification.src/M000016.html +0 -38
  58. data/doc/classes/Notify/Notification.src/M000017.html +0 -39
  59. data/doc/classes/Notify/Notification.src/M000018.html +0 -38
  60. data/doc/classes/Notify/Notification.src/M000019.html +0 -45
  61. data/doc/classes/Notify/Notification.src/M000020.html +0 -67
  62. data/doc/classes/Notify/Notification.src/M000021.html +0 -33
  63. data/doc/classes/Notify/Notification.src/M000022.html +0 -33
  64. data/doc/classes/Notify/Notification.src/M000023.html +0 -36
  65. data/doc/classes/Notify/Notification.src/M000024.html +0 -34
  66. data/doc/classes/Notify.html +0 -343
  67. data/doc/classes/Notify.src/M000001.html +0 -39
  68. data/doc/classes/Notify.src/M000002.html +0 -24
  69. data/doc/classes/Notify.src/M000003.html +0 -25
  70. data/doc/classes/Notify.src/M000004.html +0 -24
  71. data/doc/classes/Notify.src/M000005.html +0 -37
  72. data/doc/classes/Notify.src/M000006.html +0 -55
  73. data/doc/files/lib/RNotify_rb.html +0 -102
  74. data/doc/files/rnotify_c.html +0 -90
  75. data/doc/fr_class_index.html +0 -27
  76. data/doc/fr_file_index.html +0 -27
  77. data/doc/fr_method_index.html +0 -71
  78. data/doc/rdoc-style.css +0 -299
  79. data/examples/attach_to.rb +0 -43
  80. data/examples/attach_to_status_icon.rb +0 -47
  81. data/examples/geometry-hints.rb +0 -37
@@ -1,65 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>new (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * new(summ, msg, icon, widget)
13
- *
14
- * summ = The summary text (required)
15
- *
16
- * msg = The body text or nil
17
- *
18
- * icon = The icon or nil
19
- *
20
- * widget = The widget (or a Gtk::StatusIcon, when compiled against GTK+ &gt;= 2.9.2 and libnotify &gt;= 0.4.1) to attach to or nil
21
- *
22
- * Creates and returns a new notification, throw an exception on error
23
- */
24
- static VALUE
25
- _wrap_notification_init(VALUE self, VALUE summ, VALUE msg,
26
- VALUE icon, VALUE widget)
27
- {
28
- GObject *obj = G_OBJECT(RVAL2GOBJ(widget));
29
- char *nsumm = NIL_P(summ) ? NULL : StringValuePtr(summ);
30
- NotifyNotification *n = NULL;
31
-
32
- if(nsumm == NULL || *nsumm == '\0')
33
- rb_raise( rb_eArgError, &quot;REQUIRED: the `summ` field&quot; );
34
-
35
- #ifdef HAVE_STATUS_ICON
36
- if(GTK_IS_STATUS_ICON(obj))
37
- n = notify_notification_new_with_status_icon(nsumm,
38
- NIL_P(msg) ? NULL : StringValuePtr(msg),
39
- NIL_P(icon) ? NULL : StringValuePtr(icon),
40
- GTK_STATUS_ICON(obj));
41
- else
42
- n = notify_notification_new(nsumm,
43
- NIL_P(msg) ? NULL : StringValuePtr(msg),
44
- NIL_P(icon) ? NULL : StringValuePtr(icon),
45
- GTK_WIDGET(obj));
46
- #else
47
- n = notify_notification_new(nsumm,
48
- NIL_P(msg) ? NULL : StringValuePtr(msg),
49
- NIL_P(icon) ? NULL : StringValuePtr(icon),
50
- GTK_WIDGET(obj));
51
- #endif
52
-
53
- if(n == NULL)
54
- rb_raise(rb_eRuntimeError, &quot;Can not create a new notification&quot;);
55
-
56
- G_INITIALIZE(self, n);
57
-
58
- #ifdef DEBUG
59
- rb_warn(&quot;init, ok&quot;);
60
- #endif
61
-
62
- return self;
63
- }</pre>
64
- </body>
65
- </html>
@@ -1,49 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>update (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * update(summ, msg, icon)
13
- *
14
- * summ = The new summary text (required)
15
- *
16
- * msg = The new body text or nil
17
- *
18
- * icon = The new icon or nil
19
- *
20
- * This won't send the update out and display it on the screen.
21
- * For that, you will need to call the Notification#show method.
22
- *
23
- * Returns TRUE if ok, FALSE otherwise
24
- */
25
- static VALUE
26
- _wrap_notification_update(VALUE self, VALUE summ, VALUE msg, VALUE icon)
27
- {
28
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
29
- char *nsumm = NIL_P(summ) ? NULL : StringValuePtr(summ);
30
- char *nmsg = NIL_P(msg) ? NULL : StringValuePtr(msg);
31
- char *nicon = NIL_P(icon) ? NULL : StringValuePtr(icon);
32
-
33
- #ifdef DEBUG
34
- if(NOTIFY_IS_NOTIFICATION(n))
35
- rb_warn(&quot;update, ok&quot;);
36
- else
37
- rb_warn(&quot;update, no ok&quot;);
38
- #endif
39
-
40
- if(nsumm == NULL || *nsumm == '\0')
41
- rb_raise(rb_eArgError, &quot;REQUIRED: the `summ` field&quot;);
42
-
43
- if(notify_notification_update(n, nsumm, nmsg, nicon) == TRUE)
44
- return Qtrue;
45
-
46
- return Qfalse;
47
- }</pre>
48
- </body>
49
- </html>
@@ -1,43 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>attach_to (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * attach_to(widget)
13
- *
14
- * widget = The widget (or a Gtk::StatusIcon, when compiled against GTK+ &gt;= 2.9.2 and libnotify &gt;= 0.4.1) to attach to
15
- *
16
- * Attaches the notification to a Gtk::Widget or Gtk::StatusIcon
17
- */
18
- static VALUE
19
- _wrap_notification_attach_to(VALUE self, VALUE widget)
20
- {
21
- GObject *obj = G_OBJECT(RVAL2GOBJ(widget));
22
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
23
-
24
- #ifdef DEBUG
25
- if(NOTIFY_IS_NOTIFICATION(n))
26
- rb_warn(&quot;attach_to, ok&quot;);
27
- else
28
- rb_warn(&quot;attach_to, no ok&quot;);
29
- #endif
30
-
31
- #ifdef HAVE_STATUS_ICON
32
- if(GTK_IS_STATUS_ICON(obj))
33
- notify_notification_attach_to_status_icon(n, GTK_STATUS_ICON(obj));
34
- else
35
- notify_notification_attach_to_widget(n, GTK_WIDGET(obj));
36
- #else
37
- notify_notification_attach_to_widget(n, GTK_WIDGET(obj));
38
- #endif
39
-
40
- return Qnil;
41
- }</pre>
42
- </body>
43
- </html>
@@ -1,35 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>show (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * show
13
- *
14
- * Tells the notification server to display the notification on the screen.
15
- * if TRUE returns, show the notification otherwise returns FALSE
16
- */
17
- static VALUE
18
- _wrap_notification_show(VALUE self)
19
- {
20
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
21
-
22
- #ifdef DEBUG
23
- if(NOTIFY_IS_NOTIFICATION(n))
24
- rb_warn(&quot;show, ok&quot;);
25
- else
26
- rb_warn(&quot;show, no ok&quot;);
27
- #endif
28
-
29
- if(notify_notification_show(n, NULL) == TRUE)
30
- return Qtrue;
31
-
32
- return Qfalse;
33
- }</pre>
34
- </body>
35
- </html>
@@ -1,33 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>timeout= (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * timeout=(milliseconds)
13
- *
14
- * Sets the timeout in milliseconds.
15
- */
16
- static VALUE
17
- _wrap_notification_set_timeout(VALUE self, VALUE ml)
18
- {
19
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
20
-
21
- #ifdef DEBUG
22
- if(NOTIFY_IS_NOTIFICATION(n))
23
- rb_warn(&quot;timeout, ok&quot;);
24
- else
25
- rb_warn(&quot;timeout, no ok&quot;);
26
- #endif
27
-
28
- notify_notification_set_timeout(n, FIX2INT(ml));
29
-
30
- return Qnil;
31
- }</pre>
32
- </body>
33
- </html>
@@ -1,36 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>category= (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * category=(category_name)
13
- *
14
- * category_name = The category name
15
- *
16
- * Sets the category
17
- */
18
- static VALUE
19
- _wrap_notification_set_category(VALUE self, VALUE cat_name)
20
- {
21
- char *cname = NIL_P(cat_name) ? NULL : StringValuePtr(cat_name);
22
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
23
-
24
- #ifdef DEBUG
25
- if(NOTIFY_IS_NOTIFICATION(n))
26
- rb_warn(&quot;set_category, ok&quot;);
27
- else
28
- rb_warn(&quot;set_category, not ok&quot;);
29
- #endif
30
-
31
- notify_notification_set_category(n, cname);
32
-
33
- return Qnil;
34
- }</pre>
35
- </body>
36
- </html>
@@ -1,48 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>urgency= (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * urgency=(urgency_level)
13
- *
14
- * urgency_level = The urgency level
15
- *
16
- * Sets the urgency level
17
- */
18
- static VALUE
19
- _wrap_notification_set_urgency(VALUE self, VALUE urgency)
20
- {
21
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
22
-
23
- #ifdef DEBUG
24
- if(NOTIFY_IS_NOTIFICATION(n))
25
- rb_warn(&quot;set_urgency, ok&quot;);
26
- else
27
- rb_warn(&quot;set_urgency, no ok&quot;);
28
- #endif
29
-
30
- switch(FIX2INT(urgency))
31
- {
32
- case NOTIFY_URGENCY_LOW:
33
- notify_notification_set_urgency(n, NOTIFY_URGENCY_LOW);
34
- break;
35
- case NOTIFY_URGENCY_NORMAL:
36
- notify_notification_set_urgency(n, NOTIFY_URGENCY_NORMAL);
37
- break;
38
- case NOTIFY_URGENCY_CRITICAL:
39
- notify_notification_set_urgency(n, NOTIFY_URGENCY_CRITICAL);
40
- break;
41
- default:
42
- notify_notification_set_urgency(n, NOTIFY_URGENCY_NORMAL);
43
- }
44
-
45
- return Qnil;
46
- }</pre>
47
- </body>
48
- </html>
@@ -1,36 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>pixbuf_icon= (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * pixbuf_icon=(icon)
13
- *
14
- * icon = The icon
15
- *
16
- * Sets the icon from a Gdk::Pixbuf
17
- */
18
- static VALUE
19
- _wrap_notification_set_pixbuf_icon(VALUE self, VALUE icon)
20
- {
21
- GdkPixbuf *pix = GDK_PIXBUF(RVAL2GOBJ(icon));
22
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
23
-
24
- #ifdef DEBUG
25
- if(NOTIFY_IS_NOTIFICATION(n) &amp;&amp; GDK_IS_PIXBUF(pix))
26
- rb_warn(&quot;pixbuf_icon, ok&quot;);
27
- else
28
- rb_warn(&quot;pixbuf_icon, no ok&quot;);
29
- #endif
30
-
31
- notify_notification_set_icon_from_pixbuf(n, pix);
32
-
33
- return Qnil;
34
- }</pre>
35
- </body>
36
- </html>
@@ -1,38 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>hint32 (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * hint32(key, value)
13
- *
14
- * key = The hint
15
- *
16
- * value = The hint's value
17
- *
18
- * Sets a hint with a 32-bit integer value
19
- */
20
- static VALUE
21
- _wrap_notification_set_hint32(VALUE self, VALUE key, VALUE value)
22
- {
23
- char *vkey = NIL_P(key) ? NULL : StringValuePtr(key);
24
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
25
-
26
- #ifdef DEBUG
27
- if(NOTIFY_IS_NOTIFICATION(n))
28
- rb_warn(&quot;set_hint32, ok&quot;);
29
- else
30
- rb_warn(&quot;set_hint32, no ok&quot;);
31
- #endif
32
-
33
- notify_notification_set_hint_int32(n, vkey, FIX2INT(value));
34
-
35
- return Qnil;
36
- }</pre>
37
- </body>
38
- </html>
@@ -1,38 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>hint_double (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * hint_double(key, value)
13
- *
14
- * key = The hint
15
- *
16
- * value = The hint's value
17
- *
18
- * Sets a hint with a double value
19
- */
20
- static VALUE
21
- _wrap_notification_set_hint_double(VALUE self, VALUE key, VALUE value)
22
- {
23
- char *vkey = NIL_P(key) ? NULL : StringValuePtr(key);
24
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
25
-
26
- #ifdef DEBUG
27
- if(NOTIFY_IS_NOTIFICATION(n))
28
- rb_warn(&quot;set_hint_double, ok&quot;);
29
- else
30
- rb_warn(&quot;set_hint_double, no ok&quot;);
31
- #endif
32
-
33
- notify_notification_set_hint_double(n, vkey, NUM2DBL(value));
34
-
35
- return Qnil;
36
- }</pre>
37
- </body>
38
- </html>
@@ -1,39 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>hint_string (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * hint_string(key, value)
13
- *
14
- * key = The hint
15
- *
16
- * value = The hint's value
17
- *
18
- * Sets a hint with a string value
19
- */
20
- static VALUE
21
- _wrap_notification_set_hint_string(VALUE self, VALUE key, VALUE value)
22
- {
23
- char *vkey = NIL_P(key) ? NULL : StringValuePtr(key);
24
- char *vvalue = NIL_P(value) ? NULL : StringValuePtr(value);
25
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
26
-
27
- #ifdef DEBUG
28
- if(NOTIFY_IS_NOTIFICATION(n))
29
- rb_warn(&quot;set_hint_string, ok&quot;);
30
- else
31
- rb_warn(&quot;set_hint_string, no ok&quot;);
32
- #endif
33
-
34
- notify_notification_set_hint_string(n, vkey, vvalue);
35
-
36
- return Qnil;
37
- }</pre>
38
- </body>
39
- </html>
@@ -1,38 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>hint_byte (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * hint_byte(key, value)
13
- *
14
- * key = The hint
15
- *
16
- * value = The hint's value
17
- *
18
- * Sets a hint with a byte value
19
- */
20
- static VALUE
21
- _wrap_notification_set_hint_byte(VALUE self, VALUE key, VALUE value)
22
- {
23
- char *vkey = NIL_P(key) ? NULL : StringValuePtr(key);
24
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
25
-
26
- #ifdef DEBUG
27
- if(NOTIFY_IS_NOTIFICATION(n))
28
- rb_warn(&quot;set_hint_byte, ok&quot;);
29
- else
30
- rb_warn(&quot;set_hint_byte, no ok&quot;);
31
- #endif
32
-
33
- notify_notification_set_hint_byte(n, vkey, FIX2INT(value));
34
-
35
- return Qnil;
36
- }</pre>
37
- </body>
38
- </html>
@@ -1,45 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>geometry_hints (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * geometry_hints(screen, x, y)
13
- *
14
- * ** WHEN COMPILED AGAINST LIBNOTIFY 0.4.1 OR HIGHER **
15
- *
16
- * screen = The Gdk::Screen the notification should appear on
17
- *
18
- * x = The X coordinate to point to
19
- *
20
- * y = The Y coordinate to point to
21
- *
22
- * Sets the geometry hints on the notification
23
- */
24
- static VALUE
25
- _wrap_notification_set_geometry_hints(VALUE self, VALUE screen, VALUE x, VALUE y)
26
- {
27
- GdkScreen *sc = GDK_SCREEN(RVAL2GOBJ(screen));
28
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
29
-
30
- if(sc == NULL)
31
- rb_raise(rb_eArgError, &quot;REQUIRED: the `screen` field&quot;);
32
-
33
- #ifdef DEBUG
34
- if(NOTIFY_IS_NOTIFICATION(n) &amp;&amp; GDK_IS_SCREEN(sc))
35
- rb_warn(&quot;set_geometry_hints, ok&quot;);
36
- else
37
- rb_warn(&quot;set_geometry_hints, no ok&quot;);
38
- #endif
39
-
40
- notify_notification_set_geometry_hints(n, sc, FIX2INT(x), FIX2INT(y));
41
-
42
- return Qnil;
43
- }</pre>
44
- </body>
45
- </html>
@@ -1,67 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>add_action (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * add_action(action, label, user_data) { |action, user_data| ... }
13
- *
14
- * action = The action id
15
- *
16
- * label = The action label
17
- *
18
- * user_data = Custom data to pass into the block (optional)
19
- *
20
- * Adds an action. When the action is invoked, the specified block will be called
21
- *
22
- * Examples:
23
- *
24
- * myinstance.add_action( &quot;MyAction&quot;, &quot;MyLabel&quot; ) do |action|
25
- * # something to do
26
- * end
27
- *
28
- * Or
29
- *
30
- * myinstance.add_action( &quot;MyAction&quot;, &quot;MyLabel&quot;, MyData ) do |action, mydata|
31
- * # something to do
32
- * end
33
- */
34
- static VALUE
35
- _wrap_notification_add_action(int argc, VALUE *argv, VALUE self)
36
- {
37
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
38
- VALUE action, label, data, body;
39
- ActionData *actionData = NULL;
40
-
41
- #ifdef DEBUG
42
- if(NOTIFY_IS_NOTIFICATION(n))
43
- rb_warn(&quot;add_action, ok&quot;);
44
- else
45
- rb_warn(&quot;add_action, no ok&quot;);
46
- #endif
47
-
48
- if(!rb_block_given_p())
49
- rb_raise(rb_eRuntimeError, &quot;This method requires a block&quot;);
50
-
51
- rb_scan_args(argc, argv, &quot;21&amp;&quot;, &amp;action, &amp;label, &amp;data, &amp;body);
52
-
53
- actionData = g_new0(ActionData, 1);
54
- actionData-&gt;callback = body;
55
- actionData-&gt;action = action;
56
- actionData-&gt;user_data = data;
57
-
58
- notify_notification_add_action(n,
59
- NIL_P(action) ? NULL : StringValuePtr(action),
60
- NIL_P(label) ? NULL : StringValuePtr(label),
61
- (NotifyActionCallback) _notification_action_cb,
62
- actionData, (GFreeFunc)_notification_action_free);
63
-
64
- return Qnil;
65
- }</pre>
66
- </body>
67
- </html>
@@ -1,33 +0,0 @@
1
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
2
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
4
- <head>
5
- <title>clear_actions (Notify::Notification)</title>
6
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
7
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
8
- </head>
9
- <body class="standalone-code">
10
- <pre>/*
11
- * call-seq:
12
- * clear_actions
13
- *
14
- * Clears all actions from the notification. Remember to use this method before call the Notification#close method.
15
- */
16
- static VALUE
17
- _wrap_notification_clear_actions(VALUE self)
18
- {
19
- NotifyNotification *n = NOTIFY_NOTIFICATION(RVAL2GOBJ(self));
20
-
21
- #ifdef DEBUG
22
- if(NOTIFY_IS_NOTIFICATION(n))
23
- rb_warn(&quot;clear_actions, ok&quot;);
24
- else
25
- rb_warn(&quot;clear_actions, no ok&quot;);
26
- #endif
27
-
28
- notify_notification_clear_actions(n);
29
-
30
- return Qnil;
31
- }</pre>
32
- </body>
33
- </html>