~attente/gnome-software/20160331

« back to all changes in this revision

Viewing changes to debian/patches/apt-plugin.patch

  • Committer: William Hua
  • Date: 2016-04-01 01:51:50 UTC
  • Revision ID: william.hua@canonical.com-20160401015150-4qbf19c53t5p1dj0
* New upstream snapshot
* debian/patches/rename-menu-item.patch:
  - Rename 'Software Sources' menu item to 'Software & Updates'
* debian/patches/no-notification-actions.patch:
  - Disable actions in notifications (LP: #1547608)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
From 71bfaa1cc702705f52fe3e015c7eec588b20b2e6 Mon Sep 17 00:00:00 2001
 
1
From 789cd3a13775799a13ac77cd1409fc9ec93a7929 Mon Sep 17 00:00:00 2001
2
2
From: Robert Ancell <robert.ancell@canonical.com>
3
 
Date: Thu, 4 Feb 2016 14:51:21 +1300
4
 
Subject: [PATCH 09/17] Add an apt plugin that works with aptdaemon
 
3
Date: Thu, 31 Mar 2016 19:56:26 -0400
 
4
Subject: [PATCH 09/18] Add an apt plugin that works with aptdaemon
5
5
 
6
6
---
7
7
 src/gs-app.c                                 |   9 +
8
8
 src/plugins/Makefile.am                      |  19 +
9
9
 src/plugins/com.canonical.Unity.Launcher.xml |  15 +
10
 
 src/plugins/gs-plugin-apt.c                  | 976 +++++++++++++++++++++++++++
11
 
 4 files changed, 1019 insertions(+)
 
10
 src/plugins/gs-plugin-apt.c                  | 977 +++++++++++++++++++++++++++
 
11
 4 files changed, 1020 insertions(+)
12
12
 create mode 100644 src/plugins/com.canonical.Unity.Launcher.xml
13
13
 create mode 100644 src/plugins/gs-plugin-apt.c
14
14
 
33
33
                if (g_str_has_prefix (tokens[i], "@")) {
34
34
                        g_string_append_printf (urld,
35
35
diff --git a/src/plugins/Makefile.am b/src/plugins/Makefile.am
36
 
index b8d16fb..4791b89 100644
 
36
index bc4dd98..db0c971 100644
37
37
--- a/src/plugins/Makefile.am
38
38
+++ b/src/plugins/Makefile.am
39
39
@@ -31,6 +31,7 @@ noinst_LTLIBRARIES =                                  \
44
44
        libgs_plugin_appstream.la                       \
45
45
        libgs_plugin_dummy.la                           \
46
46
        libgs_plugin_hardcoded-featured.la              \
47
 
@@ -132,6 +133,24 @@ libgs_plugin_xdg_app_reviews_la_LDFLAGS = -module -avoid-version
 
47
@@ -135,6 +136,24 @@ libgs_plugin_xdg_app_reviews_la_LDFLAGS = -module -avoid-version
48
48
 libgs_plugin_xdg_app_reviews_la_CFLAGS = $(GS_PLUGIN_CFLAGS) $(WARN_CFLAGS)
49
49
 endif
50
50
 
71
71
        gs-moduleset.h                                  \
72
72
diff --git a/src/plugins/com.canonical.Unity.Launcher.xml b/src/plugins/com.canonical.Unity.Launcher.xml
73
73
new file mode 100644
74
 
index 0000000..b0d7915
 
74
index 0000000..b631a2d
75
75
--- /dev/null
76
76
+++ b/src/plugins/com.canonical.Unity.Launcher.xml
77
77
@@ -0,0 +1,15 @@
83
83
+      <arg type='s' name='appstream_app_id' direction='in'/>
84
84
+      <arg type='s' name='aptdaemon_task' direction='in'/>
85
85
+    </method>
86
 
+
 
86
+    
87
87
+    <method name='UpdateLauncherIconFavoriteState'>
88
88
+      <arg type='s' name='icon_uri' direction='in'/>
89
89
+      <arg type='b' name='is_sticky' direction='in'/>
92
92
+</node>
93
93
diff --git a/src/plugins/gs-plugin-apt.c b/src/plugins/gs-plugin-apt.c
94
94
new file mode 100644
95
 
index 0000000..d5c54f1
 
95
index 0000000..d9af67a
96
96
--- /dev/null
97
97
+++ b/src/plugins/gs-plugin-apt.c
98
 
@@ -0,0 +1,976 @@
 
98
@@ -0,0 +1,977 @@
99
99
+/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*-
100
100
+ *
101
101
+ * Copyright (C) 2016 Canonical Ltd
1067
1067
+       gs_app_set_management_plugin (app, "dpkg");
1068
1068
+       gs_app_add_source (app, tokens[0]);
1069
1069
+       gs_app_set_origin (app, path);
 
1070
+       gs_app_set_kind (app, AS_APP_KIND_GENERIC);
1070
1071
+
1071
1072
+       gs_plugin_add_app (list, app);
1072
1073
+