summaryrefslogtreecommitdiffstats
path: root/config/chroot_local-patches/Desktop-Notify:_0002-support_hints.patch
blob: 2c9eec1dbc1f5c2f524056220c7c1b5ba3dbad14 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
From fc56108b83af0e4966ad615730d09e9bc11b865c Mon Sep 17 00:00:00 2001
From: intrigeri <intrigeri@boum.org>
Date: Mon, 9 Mar 2015 00:46:12 +0000
Subject: [PATCH 2/2] Add support for passing hints to the notification server.

---
 lib/Desktop/Notify/Notification.pm | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

diff --git a/lib/Desktop/Notify/Notification.pm b/lib/Desktop/Notify/Notification.pm
index e7710e8..0ac09cb 100644
--- a/usr/share/perl5/Desktop/Notify/Notification.pm
+++ b/usr/share/perl5/Desktop/Notify/Notification.pm
@@ -60,6 +60,7 @@ sub new {
     $self->{server} = $server;
     $self->{id} = undef;
     $self->{actions} ||= {};
+    $self->{hints}   ||= {};
     bless $self, $class;
 }
 
@@ -83,7 +84,7 @@ sub show {
                  $self->{summary},
                  $self->{body},
                  [%{$self->{actions}}],
-                 {},
+                 $self->{hints},
                  $self->{timeout} || 0,
                 );
     $self->{server}->_register_notification($self);
@@ -135,6 +136,12 @@ element in the list is the localized string that will be displayed to the user.
 A user-specified function to be called whenever an action is invoked can be
 specified with L<Desktop::Notify>'s L<action_callback> method.
 
+=item hints
+
+Optional hints that can be passed to the server from the client program.
+
+=back
+
 =item timeout
 
 The timeout time in milliseconds since the display of the notification at which
@@ -155,12 +162,6 @@ supported by L<Desktop::Notify> at this time
 
 The optional program icon of the calling application.
 
-=item hints
-
-Optional hints that can be passed to the server from the client program.
-
-=back
-
 =cut
 
 1;  # End of Desktop::Notify::Notification
-- 
2.1.4