Add some patches
This commit is contained in:
parent
67058dc21b
commit
5c34167d7f
50
0001-KYOS-B-Fix-mate-settings-daemon-crash.patch
Normal file
50
0001-KYOS-B-Fix-mate-settings-daemon-crash.patch
Normal file
@ -0,0 +1,50 @@
|
||||
From e0ed56cc90f28e0988363ca9bd109bbd3c234fd5 Mon Sep 17 00:00:00 2001
|
||||
From: songchuanfei <songchuanfei@kylinos.com.cn>
|
||||
Date: Thu, 23 Apr 2020 11:40:48 +0800
|
||||
Subject: [PATCH] KYOS-B: Fix mate-settings-daemon crash
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
- 修复mate-settings-daemon启动时崩溃的问题,具体原因不明
|
||||
|
||||
Signed-off-by: songchuanfei <songchuanfei@kylinos.com.cn>
|
||||
---
|
||||
libmate-desktop/mate-rr.c | 18 +++++++++++++++++-
|
||||
1 file changed, 17 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/libmate-desktop/mate-rr.c b/libmate-desktop/mate-rr.c
|
||||
index a9bdf79..ed2607e 100644
|
||||
--- a/libmate-desktop/mate-rr.c
|
||||
+++ b/libmate-desktop/mate-rr.c
|
||||
@@ -1205,10 +1205,26 @@ read_edid_data (MateRROutput *output, int *len)
|
||||
|
||||
static gboolean check_hotplug_mode_update(MateRROutput *output)
|
||||
{
|
||||
+#ifdef HAVE_RANDR
|
||||
Atom atom;
|
||||
+ int len;
|
||||
+ guint8 *result;
|
||||
|
||||
atom = XInternAtom(DISPLAY(output), "hotplug_mode_update", FALSE);
|
||||
- return (XRRQueryOutputProperty(DISPLAY(output), output->id, atom) != NULL);
|
||||
+ if (atom == None)
|
||||
+ return FALSE;
|
||||
+ result = get_property (DISPLAY (output),
|
||||
+ output->id, atom, &len);
|
||||
+
|
||||
+ if (result) {
|
||||
+ g_free(result);
|
||||
+ return TRUE;
|
||||
+ } else
|
||||
+ return FALSE;
|
||||
+
|
||||
+#else
|
||||
+ return FALSE;
|
||||
+#endif
|
||||
}
|
||||
|
||||
gboolean mate_rr_output_has_hotplug_mode_update(MateRROutput *output)
|
||||
--
|
||||
1.8.3.1
|
||||
|
||||
127
0001-KYOS-F-Add-api-to-check-hotplug_mode_update-property.patch
Normal file
127
0001-KYOS-F-Add-api-to-check-hotplug_mode_update-property.patch
Normal file
@ -0,0 +1,127 @@
|
||||
From 8fd6a3dc1ca2cf4c728ba61a86055320c1257383 Mon Sep 17 00:00:00 2001
|
||||
From: songchuanfei <songchuanfei@kylinos.com.cn>
|
||||
Date: Tue, 7 Apr 2020 17:13:46 +0800
|
||||
Subject: [PATCH] KYOS-F: Add api to check hotplug_mode_update property for
|
||||
outputs
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
- 添加检查给定输出的hotplug_mode_update属性的接口,该属性标记了虚拟屏幕(Virtural Screen)
|
||||
|
||||
Signed-off-by: songchuanfei <songchuanfei@kylinos.com.cn>
|
||||
---
|
||||
libmate-desktop/mate-rr-config.c | 1 +
|
||||
libmate-desktop/mate-rr-config.h | 2 ++
|
||||
libmate-desktop/mate-rr-output-info.c | 5 +++++
|
||||
libmate-desktop/mate-rr-private.h | 1 +
|
||||
libmate-desktop/mate-rr.c | 16 ++++++++++++++++
|
||||
libmate-desktop/mate-rr.h | 1 +
|
||||
6 files changed, 26 insertions(+)
|
||||
|
||||
diff --git a/libmate-desktop/mate-rr-config.c b/libmate-desktop/mate-rr-config.c
|
||||
index 09d2b8f..3609292 100644
|
||||
--- a/libmate-desktop/mate-rr-config.c
|
||||
+++ b/libmate-desktop/mate-rr-config.c
|
||||
@@ -518,6 +518,7 @@ mate_rr_config_load_current (MateRRConfig *config, GError **error)
|
||||
|
||||
output->priv->name = g_strdup (mate_rr_output_get_name (rr_output));
|
||||
output->priv->connected = mate_rr_output_is_connected (rr_output);
|
||||
+ output->priv->hotplug_mode_update = mate_rr_output_has_hotplug_mode_update (rr_output);
|
||||
|
||||
if (!output->priv->connected)
|
||||
{
|
||||
diff --git a/libmate-desktop/mate-rr-config.h b/libmate-desktop/mate-rr-config.h
|
||||
index 85c8c9f..2f16d52 100644
|
||||
--- a/libmate-desktop/mate-rr-config.h
|
||||
+++ b/libmate-desktop/mate-rr-config.h
|
||||
@@ -87,6 +87,8 @@ void mate_rr_output_info_set_primary (MateRROutputInfo *self, gboolean prima
|
||||
int mate_rr_output_info_get_preferred_width (MateRROutputInfo *self);
|
||||
int mate_rr_output_info_get_preferred_height (MateRROutputInfo *self);
|
||||
|
||||
+gboolean mate_rr_output_info_has_hotplug_mode_update (MateRROutputInfo *self);
|
||||
+
|
||||
typedef struct
|
||||
{
|
||||
GObject parent;
|
||||
diff --git a/libmate-desktop/mate-rr-output-info.c b/libmate-desktop/mate-rr-output-info.c
|
||||
index 9761e9c..85ee50b 100644
|
||||
--- a/libmate-desktop/mate-rr-output-info.c
|
||||
+++ b/libmate-desktop/mate-rr-output-info.c
|
||||
@@ -250,3 +250,8 @@ int mate_rr_output_info_get_preferred_height (MateRROutputInfo *self)
|
||||
|
||||
return self->priv->pref_height;
|
||||
}
|
||||
+
|
||||
+gboolean mate_rr_output_info_has_hotplug_mode_update (MateRROutputInfo *self)
|
||||
+{
|
||||
+ return self->priv->hotplug_mode_update;
|
||||
+}
|
||||
diff --git a/libmate-desktop/mate-rr-private.h b/libmate-desktop/mate-rr-private.h
|
||||
index d5410ca..fa14368 100644
|
||||
--- a/libmate-desktop/mate-rr-private.h
|
||||
+++ b/libmate-desktop/mate-rr-private.h
|
||||
@@ -70,6 +70,7 @@ struct MateRROutputInfoPrivate
|
||||
int pref_height;
|
||||
char * display_name;
|
||||
gboolean primary;
|
||||
+ gboolean hotplug_mode_update;
|
||||
};
|
||||
|
||||
struct MateRRConfigPrivate
|
||||
diff --git a/libmate-desktop/mate-rr.c b/libmate-desktop/mate-rr.c
|
||||
index 04ffd0d..a9bdf79 100644
|
||||
--- a/libmate-desktop/mate-rr.c
|
||||
+++ b/libmate-desktop/mate-rr.c
|
||||
@@ -89,6 +89,7 @@ struct MateRROutput
|
||||
int n_preferred;
|
||||
guint8 * edid_data;
|
||||
int edid_size;
|
||||
+ gboolean hotplug_mode_update;
|
||||
char * connector_type;
|
||||
};
|
||||
|
||||
@@ -1202,6 +1203,19 @@ read_edid_data (MateRROutput *output, int *len)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
+static gboolean check_hotplug_mode_update(MateRROutput *output)
|
||||
+{
|
||||
+ Atom atom;
|
||||
+
|
||||
+ atom = XInternAtom(DISPLAY(output), "hotplug_mode_update", FALSE);
|
||||
+ return (XRRQueryOutputProperty(DISPLAY(output), output->id, atom) != NULL);
|
||||
+}
|
||||
+
|
||||
+gboolean mate_rr_output_has_hotplug_mode_update(MateRROutput *output)
|
||||
+{
|
||||
+ return output->hotplug_mode_update;
|
||||
+}
|
||||
+
|
||||
static char *
|
||||
get_connector_type_string (MateRROutput *output)
|
||||
{
|
||||
@@ -1315,6 +1329,8 @@ output_initialize (MateRROutput *output, XRRScreenResources *res, GError **error
|
||||
|
||||
/* Edid data */
|
||||
output->edid_data = read_edid_data (output, &output->edid_size);
|
||||
+
|
||||
+ output->hotplug_mode_update = check_hotplug_mode_update(output);
|
||||
|
||||
XRRFreeOutputInfo (info);
|
||||
|
||||
diff --git a/libmate-desktop/mate-rr.h b/libmate-desktop/mate-rr.h
|
||||
index cc7e427..be3e7e8 100644
|
||||
--- a/libmate-desktop/mate-rr.h
|
||||
+++ b/libmate-desktop/mate-rr.h
|
||||
@@ -146,6 +146,7 @@ MateRRMode * mate_rr_output_get_preferred_mode (MateRROutput *output);
|
||||
gboolean mate_rr_output_supports_mode (MateRROutput *output,
|
||||
MateRRMode *mode);
|
||||
gboolean mate_rr_output_get_is_primary (MateRROutput *output);
|
||||
+gboolean mate_rr_output_has_hotplug_mode_update (MateRROutput *output);
|
||||
|
||||
/* MateRRMode */
|
||||
guint32 mate_rr_mode_get_id (MateRRMode *mode);
|
||||
--
|
||||
2.18.1
|
||||
|
||||
230
0001-add-the-gdk-window-scale-settings.patch
Normal file
230
0001-add-the-gdk-window-scale-settings.patch
Normal file
@ -0,0 +1,230 @@
|
||||
From 85ff3ca6b09f8fb72cb070ae21105c8a4d058234 Mon Sep 17 00:00:00 2001
|
||||
From: wangxiaoqing <wangxiaoqing@kylinos.com.cn>
|
||||
Date: Fri, 22 May 2020 19:11:59 +0800
|
||||
Subject: [PATCH] add the gdk window scale settings
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
- 添加gdk窗口缩放设置接口,Related #25310
|
||||
---
|
||||
libmate-desktop/mate-rr-config.c | 61 ++++++++++++++++++++++++---
|
||||
libmate-desktop/mate-rr-output-info.c | 14 ++++++
|
||||
libmate-desktop/mate-rr-private.h | 2 +
|
||||
3 files changed, 71 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/libmate-desktop/mate-rr-config.c b/libmate-desktop/mate-rr-config.c
|
||||
index 3609292..d2831df 100644
|
||||
--- a/libmate-desktop/mate-rr-config.c
|
||||
+++ b/libmate-desktop/mate-rr-config.c
|
||||
@@ -44,6 +44,9 @@
|
||||
#define CONFIG_INTENDED_BASENAME "monitors.xml"
|
||||
#define CONFIG_BACKUP_BASENAME "monitors.xml.backup"
|
||||
|
||||
+#define MSD_INTERFACE_SCHEMA "org.mate.interface"
|
||||
+#define WINDOW_SCALE_KEY "window-scaling-factor"
|
||||
+
|
||||
/* In version 0 of the config file format, we had several <configuration>
|
||||
* toplevel elements and no explicit version number. So, the filed looked
|
||||
* like
|
||||
@@ -341,6 +344,21 @@ handle_text (GMarkupParseContext *context,
|
||||
parser->output->priv->rotation |= MATE_RR_ROTATION_270;
|
||||
}
|
||||
}
|
||||
+ else if (stack_is (parser, "scale", "output", "configuration", TOPLEVEL_ELEMENT, NULL))
|
||||
+ {
|
||||
+ if (strcmp (text, "100%") == 0)
|
||||
+ {
|
||||
+ parser->output->priv->scale = 1;
|
||||
+ }
|
||||
+ else if (strcmp (text, "200%") == 0)
|
||||
+ {
|
||||
+ parser->output->priv->scale = 2;
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ parser->output->priv->scale = 0;
|
||||
+ }
|
||||
+ }
|
||||
else if (stack_is (parser, "reflect_x", "output", "configuration", TOPLEVEL_ELEMENT, NULL))
|
||||
{
|
||||
if (strcmp (text, "yes") == 0)
|
||||
@@ -454,6 +472,7 @@ mate_rr_config_init (MateRRConfig *self)
|
||||
self->priv->clone = FALSE;
|
||||
self->priv->screen = NULL;
|
||||
self->priv->outputs = NULL;
|
||||
+ self->priv->ws_settings = g_settings_new (MSD_INTERFACE_SCHEMA);
|
||||
}
|
||||
|
||||
static void
|
||||
@@ -487,6 +506,8 @@ mate_rr_config_finalize (GObject *gobject)
|
||||
}
|
||||
g_free (self->priv->outputs);
|
||||
}
|
||||
+
|
||||
+ g_object_unref (self->priv->ws_settings);
|
||||
|
||||
G_OBJECT_CLASS (mate_rr_config_parent_class)->finalize (gobject);
|
||||
}
|
||||
@@ -500,6 +521,7 @@ mate_rr_config_load_current (MateRRConfig *config, GError **error)
|
||||
int clone_width = -1;
|
||||
int clone_height = -1;
|
||||
int last_x;
|
||||
+ int scale = 0;
|
||||
|
||||
g_return_val_if_fail (MATE_IS_RR_CONFIG (config), FALSE);
|
||||
|
||||
@@ -507,6 +529,9 @@ mate_rr_config_load_current (MateRRConfig *config, GError **error)
|
||||
rr_outputs = mate_rr_screen_list_outputs (config->priv->screen);
|
||||
|
||||
config->priv->clone = FALSE;
|
||||
+
|
||||
+ /*window scale for gdk */
|
||||
+ scale = g_settings_get_int(config->priv->ws_settings, WINDOW_SCALE_KEY);
|
||||
|
||||
for (i = 0; rr_outputs[i] != NULL; ++i)
|
||||
{
|
||||
@@ -519,6 +544,7 @@ mate_rr_config_load_current (MateRRConfig *config, GError **error)
|
||||
output->priv->name = g_strdup (mate_rr_output_get_name (rr_output));
|
||||
output->priv->connected = mate_rr_output_is_connected (rr_output);
|
||||
output->priv->hotplug_mode_update = mate_rr_output_has_hotplug_mode_update (rr_output);
|
||||
+ output->priv->scale = scale;
|
||||
|
||||
if (!output->priv->connected)
|
||||
{
|
||||
@@ -962,6 +988,7 @@ make_outputs (MateRRConfig *config)
|
||||
new->priv->width = first_on->priv->width;
|
||||
new->priv->height = first_on->priv->height;
|
||||
new->priv->rotation = first_on->priv->rotation;
|
||||
+ new->priv->scale = first_on->priv->scale;
|
||||
new->priv->x = 0;
|
||||
new->priv->y = 0;
|
||||
}
|
||||
@@ -1045,6 +1072,17 @@ get_rotation_name (MateRRRotation r)
|
||||
return "normal";
|
||||
}
|
||||
|
||||
+static const char *
|
||||
+get_scale_name (int scale)
|
||||
+{
|
||||
+ if ( scale == 2)
|
||||
+ return "200%";
|
||||
+ if ( scale == 1)
|
||||
+ return "100%";
|
||||
+
|
||||
+ return "auto";
|
||||
+}
|
||||
+
|
||||
static const char *
|
||||
yes_no (int x)
|
||||
{
|
||||
@@ -1105,6 +1143,8 @@ emit_configuration (MateRRConfig *config,
|
||||
string, " <y>%d</y>\n", output->priv->y);
|
||||
g_string_append_printf (
|
||||
string, " <rotation>%s</rotation>\n", get_rotation_name (output->priv->rotation));
|
||||
+ g_string_append_printf (
|
||||
+ string, " <scale>%s</scale>\n", get_scale_name (output->priv->scale));
|
||||
g_string_append_printf (
|
||||
string, " <reflect_x>%s</reflect_x>\n", get_reflect_x (output->priv->rotation));
|
||||
g_string_append_printf (
|
||||
@@ -1279,6 +1319,14 @@ mate_rr_config_save (MateRRConfig *configuration, GError **error)
|
||||
return result;
|
||||
}
|
||||
|
||||
+struct CrtcAssignment
|
||||
+{
|
||||
+ MateRRScreen *screen;
|
||||
+ GHashTable *info;
|
||||
+ MateRROutput *primary;
|
||||
+ int scale;
|
||||
+};
|
||||
+
|
||||
gboolean
|
||||
mate_rr_config_apply_with_time (MateRRConfig *config,
|
||||
MateRRScreen *screen,
|
||||
@@ -1307,10 +1355,14 @@ mate_rr_config_apply_with_time (MateRRConfig *config,
|
||||
if (crtc_assignment_apply (assignment, timestamp, error))
|
||||
result = TRUE;
|
||||
|
||||
+ g_settings_set_int(config->priv->ws_settings, WINDOW_SCALE_KEY, assignment->scale);
|
||||
+
|
||||
crtc_assignment_free (assignment);
|
||||
|
||||
display = gdk_display_get_default ();
|
||||
gdk_display_flush (display);
|
||||
+
|
||||
+
|
||||
}
|
||||
|
||||
return result;
|
||||
@@ -1439,12 +1491,6 @@ struct CrtcInfo
|
||||
GPtrArray *outputs;
|
||||
};
|
||||
|
||||
-struct CrtcAssignment
|
||||
-{
|
||||
- MateRRScreen *screen;
|
||||
- GHashTable *info;
|
||||
- MateRROutput *primary;
|
||||
-};
|
||||
|
||||
static gboolean
|
||||
can_clone (CrtcInfo *info,
|
||||
@@ -1693,6 +1739,9 @@ real_assign_crtcs (MateRRScreen *screen,
|
||||
tried_mode = FALSE;
|
||||
accumulated_error = g_string_new (NULL);
|
||||
|
||||
+ /* all outputs use a scale */
|
||||
+ assignment->scale = output->priv->scale;
|
||||
+
|
||||
for (i = 0; crtcs[i] != NULL; ++i)
|
||||
{
|
||||
MateRRCrtc *crtc = crtcs[i];
|
||||
diff --git a/libmate-desktop/mate-rr-output-info.c b/libmate-desktop/mate-rr-output-info.c
|
||||
index 85ee50b..3c56930 100644
|
||||
--- a/libmate-desktop/mate-rr-output-info.c
|
||||
+++ b/libmate-desktop/mate-rr-output-info.c
|
||||
@@ -162,6 +162,20 @@ void mate_rr_output_info_set_rotation (MateRROutputInfo *self, MateRRRotation ro
|
||||
self->priv->rotation = rotation;
|
||||
}
|
||||
|
||||
+int mate_rr_output_info_get_scale (MateRROutputInfo *self)
|
||||
+{
|
||||
+ g_return_val_if_fail (MATE_IS_RR_OUTPUT_INFO (self), 0);
|
||||
+
|
||||
+ return self->priv->scale;
|
||||
+}
|
||||
+
|
||||
+void mate_rr_output_info_set_scale (MateRROutputInfo *self, int scale)
|
||||
+{
|
||||
+ g_return_if_fail (MATE_IS_RR_OUTPUT_INFO (self));
|
||||
+
|
||||
+ self->priv->scale = scale;
|
||||
+}
|
||||
+
|
||||
/**
|
||||
* mate_rr_output_info_is_connected:
|
||||
*
|
||||
diff --git a/libmate-desktop/mate-rr-private.h b/libmate-desktop/mate-rr-private.h
|
||||
index fa14368..ee3ec42 100644
|
||||
--- a/libmate-desktop/mate-rr-private.h
|
||||
+++ b/libmate-desktop/mate-rr-private.h
|
||||
@@ -60,6 +60,7 @@ struct MateRROutputInfoPrivate
|
||||
int x;
|
||||
int y;
|
||||
MateRRRotation rotation;
|
||||
+ int scale;
|
||||
|
||||
gboolean connected;
|
||||
gchar vendor[4];
|
||||
@@ -78,6 +79,7 @@ struct MateRRConfigPrivate
|
||||
gboolean clone;
|
||||
MateRRScreen *screen;
|
||||
MateRROutputInfo **outputs;
|
||||
+ GSettings *ws_settings;
|
||||
};
|
||||
|
||||
gboolean _mate_rr_output_name_is_laptop (const char *name);
|
||||
--
|
||||
2.20.1
|
||||
|
||||
48
0001-changed-font-name-kylin-1.22.1.patch
Normal file
48
0001-changed-font-name-kylin-1.22.1.patch
Normal file
@ -0,0 +1,48 @@
|
||||
From 3c0ce7d6bd4b79253eb6b9a5c54d70d1c2411da5 Mon Sep 17 00:00:00 2001
|
||||
From: mazhiguo <mazhiguo@kylinos.com.cn>
|
||||
Date: Wed, 4 Sep 2019 21:51:09 -0400
|
||||
Subject: [PATCH] changed font name kylin 1.22.1
|
||||
|
||||
---
|
||||
po/zh_CN.po | 2 +-
|
||||
schemas/org.mate.interface.gschema.xml.in | 4 ++--
|
||||
2 files changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/po/zh_CN.po b/po/zh_CN.po
|
||||
index 4b1f842..99225a9 100644
|
||||
--- a/po/zh_CN.po
|
||||
+++ b/po/zh_CN.po
|
||||
@@ -1485,7 +1485,7 @@ msgstr "是否允许键盘锁定。"
|
||||
|
||||
#: ../tools/mate-color-select.c:64 ../tools/mate-color-select.desktop.in.h:1
|
||||
msgid "MATE Color Selection"
|
||||
-msgstr "MATE 颜色选择"
|
||||
+msgstr "颜色选择"
|
||||
|
||||
#: ../tools/mate-color-select.desktop.in.h:2
|
||||
msgid "Color selection dialog"
|
||||
diff --git a/schemas/org.mate.interface.gschema.xml.in b/schemas/org.mate.interface.gschema.xml.in
|
||||
index bcb2a61..a4c51a6 100644
|
||||
--- a/schemas/org.mate.interface.gschema.xml.in
|
||||
+++ b/schemas/org.mate.interface.gschema.xml.in
|
||||
@@ -76,7 +76,7 @@
|
||||
<description>A '\n' separated list of "name:color" as defined by the 'gtk-color-scheme' setting</description>
|
||||
</key>
|
||||
<key name="font-name" type="s">
|
||||
- <default>'Sans 10'</default>
|
||||
+ <default>'Noto Sans CJK SC Regular 9'</default>
|
||||
<summary>Default font</summary>
|
||||
<description>Name of the default font used by gtk+.</description>
|
||||
</key>
|
||||
@@ -111,7 +111,7 @@
|
||||
<description>Whether to enable toolkit-wide animations.</description>
|
||||
</key>
|
||||
<key name="document-font-name" type="s">
|
||||
- <default>'Sans 10'</default>
|
||||
+ <default>'Noto Sans CJK SC Regular 10'</default>
|
||||
<summary>Document font</summary>
|
||||
<description>Name of the default font used for reading documents.</description>
|
||||
</key>
|
||||
--
|
||||
2.18.1
|
||||
|
||||
@ -0,0 +1,67 @@
|
||||
From b4b0b5f5a39dd66b7d752af4177119c43f316f3a Mon Sep 17 00:00:00 2001
|
||||
From: songchuanfei <songchuanfei@kylinos.com.cn>
|
||||
Date: Thu, 27 Aug 2020 16:48:59 +0800
|
||||
Subject: [PATCH] feature[lockdown,settings]: Add lockdown settings for reboot
|
||||
and suspend
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
- 为系统重启和系统挂起添加可禁用的配置
|
||||
Resolves #29094
|
||||
|
||||
Signed-off-by: songchuanfei <songchuanfei@kylinos.com.cn>
|
||||
---
|
||||
po/zh_CN.po | 14 ++++++++++++++
|
||||
schemas/org.mate.lockdown.gschema.xml.in | 10 ++++++++++
|
||||
2 files changed, 24 insertions(+)
|
||||
|
||||
diff --git a/po/zh_CN.po b/po/zh_CN.po
|
||||
index 99225a9..a8e4cf0 100644
|
||||
--- a/po/zh_CN.po
|
||||
+++ b/po/zh_CN.po
|
||||
@@ -1228,6 +1228,20 @@ msgid ""
|
||||
"active."
|
||||
msgstr "阻止用户在自己的会话活动时切换到另一个账户。"
|
||||
|
||||
+msgid "Disable reboot"
|
||||
+msgstr "禁止重启系统"
|
||||
+
|
||||
+msgid ""
|
||||
+"Prevent the user from reboot the system."
|
||||
+msgstr "阻止用户重启系统"
|
||||
+
|
||||
+msgid "Disable power suspend"
|
||||
+msgstr "禁用系统休眠"
|
||||
+
|
||||
+msgid ""
|
||||
+"Prevent the user from suspend the system."
|
||||
+msgstr "阻止用户挂起系统或将系统休眠"
|
||||
+
|
||||
#: ../schemas/org.mate.lockdown.gschema.xml.in.h:11
|
||||
msgid "Disable lock screen"
|
||||
msgstr "禁用锁屏"
|
||||
diff --git a/schemas/org.mate.lockdown.gschema.xml.in b/schemas/org.mate.lockdown.gschema.xml.in
|
||||
index 1517bd1..2f5b7c5 100644
|
||||
--- a/schemas/org.mate.lockdown.gschema.xml.in
|
||||
+++ b/schemas/org.mate.lockdown.gschema.xml.in
|
||||
@@ -30,6 +30,16 @@
|
||||
<summary>Disable lock screen</summary>
|
||||
<description>Prevent the user from locking the screen.</description>
|
||||
</key>
|
||||
+ <key name="disable-reboot" type="b">
|
||||
+ <default>false</default>
|
||||
+ <summary>Disable reboot</summary>
|
||||
+ <description>Prevent the user from reboot the system.</description>
|
||||
+ </key>
|
||||
+ <key name="disable-suspend" type="b">
|
||||
+ <default>false</default>
|
||||
+ <summary>Disable power suspend</summary>
|
||||
+ <description>Prevent the user from suspend the system.</description>
|
||||
+ </key>
|
||||
<key name="disable-application-handlers" type="b">
|
||||
<default>false</default>
|
||||
<summary>Disable URL and MIME type handlers</summary>
|
||||
--
|
||||
2.18.1
|
||||
|
||||
@ -0,0 +1,54 @@
|
||||
From 72886b6a61b918d376fd118cb2687b9ecd5d9ebe Mon Sep 17 00:00:00 2001
|
||||
From: songchuanfei <songchuanfei@kylinos.com.cn>
|
||||
Date: Tue, 10 Nov 2020 13:43:05 +0800
|
||||
Subject: [PATCH] fix[xrandr]: Fix virtual screens not recognized
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
- 修复无法通过hotplug_mode_update属性区分虚拟屏幕的问题
|
||||
---
|
||||
libmate-desktop/mate-rr.c | 20 +++++++++++---------
|
||||
1 file changed, 11 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/libmate-desktop/mate-rr.c b/libmate-desktop/mate-rr.c
|
||||
index ed2607e..36b0fc0 100644
|
||||
--- a/libmate-desktop/mate-rr.c
|
||||
+++ b/libmate-desktop/mate-rr.c
|
||||
@@ -1206,22 +1206,24 @@ read_edid_data (MateRROutput *output, int *len)
|
||||
static gboolean check_hotplug_mode_update(MateRROutput *output)
|
||||
{
|
||||
#ifdef HAVE_RANDR
|
||||
+ GdkDisplay *display;
|
||||
Atom atom;
|
||||
- int len;
|
||||
- guint8 *result;
|
||||
+ XRRPropertyInfo *info = NULL;
|
||||
|
||||
atom = XInternAtom(DISPLAY(output), "hotplug_mode_update", FALSE);
|
||||
if (atom == None)
|
||||
return FALSE;
|
||||
- result = get_property (DISPLAY (output),
|
||||
- output->id, atom, &len);
|
||||
|
||||
- if (result) {
|
||||
- g_free(result);
|
||||
- return TRUE;
|
||||
- } else
|
||||
- return FALSE;
|
||||
+ display = gdk_display_get_default ();
|
||||
+ gdk_x11_display_error_trap_push (display);
|
||||
+ info = XRRQueryOutputProperty (DISPLAY(output), output->id, atom);
|
||||
+ gdk_x11_display_error_trap_pop_ignored (display);
|
||||
|
||||
+ if (info) {
|
||||
+ XFree(info);
|
||||
+ return TRUE;
|
||||
+ }
|
||||
+ return FALSE;
|
||||
#else
|
||||
return FALSE;
|
||||
#endif
|
||||
--
|
||||
2.18.4
|
||||
|
||||
@ -17,7 +17,7 @@ Name: mate-desktop
|
||||
License: GPLv2+ and LGPLv2+ and MIT
|
||||
Version: %{branch}.2
|
||||
%if 0%{?rel_build}
|
||||
Release: 5
|
||||
Release: 6
|
||||
%else
|
||||
Release: 0.10%{?git_rel}
|
||||
%endif
|
||||
@ -36,6 +36,13 @@ Source3: mate-fedora-f31.gschema.override
|
||||
Source4: mate-rhel.gschema.override
|
||||
Source5: mate-mimeapps.list
|
||||
|
||||
Patch1001: 0001-changed-font-name-kylin-1.22.1.patch
|
||||
Patch1002: 0001-KYOS-F-Add-api-to-check-hotplug_mode_update-property.patch
|
||||
Patch1003: 0001-KYOS-B-Fix-mate-settings-daemon-crash.patch
|
||||
Patch1004: 0001-add-the-gdk-window-scale-settings.patch
|
||||
Patch1005: 0001-feature-lockdown-settings-Add-lockdown-settings-for-.patch
|
||||
Patch1006: 0001-fix-xrandr-Fix-virtual-screens-not-recognized-72886b6a.patch
|
||||
|
||||
BuildRequires: dconf-devel
|
||||
BuildRequires: desktop-file-utils
|
||||
BuildRequires: gobject-introspection-devel
|
||||
@ -49,7 +56,13 @@ BuildRequires: cairo-gobject-devel
|
||||
BuildRequires: gdb-headless
|
||||
|
||||
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
|
||||
%if 0%{?openEuler}
|
||||
Requires: openEuler-menus
|
||||
%endif
|
||||
%if 0%{?rhel}
|
||||
Requires: redhat-menus
|
||||
%endif
|
||||
|
||||
Requires: xdg-user-dirs-gtk
|
||||
Requires: mate-control-center-filesystem
|
||||
Requires: mate-panel
|
||||
@ -64,6 +77,7 @@ Requires: f30-backgrounds-mate
|
||||
%if 0%{?fedora} && 0%{?fedora} == 29
|
||||
Requires: f29-backgrounds-mate
|
||||
%endif
|
||||
Requires: google-noto-sans-cjk-sc-fonts
|
||||
|
||||
%if 0%{?fedora}
|
||||
# Need this to pull in the right imsettings in groupinstalls
|
||||
@ -107,7 +121,7 @@ Obsoletes: libmatewnck-devel
|
||||
Obsoletes: mate-user-share
|
||||
%endif
|
||||
|
||||
%if 0%{?fedora} || 0%{?rhel}
|
||||
%if 0%{?fedora} || 0%{?rhel} || 0%{?openEuler}
|
||||
Obsoletes: mate-dialogs
|
||||
%endif
|
||||
|
||||
@ -190,7 +204,7 @@ install -D -m 0644 %SOURCE2 %{buildroot}%{_datadir}/glib-2.0/schemas/10_mate-fed
|
||||
install -D -m 0644 %SOURCE3 %{buildroot}%{_datadir}/glib-2.0/schemas/10_mate-fedora.gschema.override
|
||||
%endif
|
||||
|
||||
%if 0%{?rhel}
|
||||
%if 0%{?rhel} || 0%{?openEuler}
|
||||
install -D -m 0644 %SOURCE4 %{buildroot}%{_datadir}/glib-2.0/schemas/10_mate-rhel.gschema.override
|
||||
%endif
|
||||
|
||||
@ -211,7 +225,7 @@ install -m 644 %SOURCE5 %{buildroot}/%{_datadir}/applications/mate-mimeapps.list
|
||||
%if 0%{?fedora}
|
||||
%{_datadir}/glib-2.0/schemas/10_mate-fedora.gschema.override
|
||||
%endif
|
||||
%if 0%{?rhel}
|
||||
%if 0%{?rhel} || 0%{?openEuler}
|
||||
%{_datadir}/glib-2.0/schemas/10_mate-rhel.gschema.override
|
||||
%endif
|
||||
%{_datadir}/icons/hicolor/*/apps/*.png
|
||||
@ -233,8 +247,17 @@ install -m 644 %SOURCE5 %{buildroot}/%{_datadir}/applications/mate-mimeapps.list
|
||||
|
||||
|
||||
%changelog
|
||||
* Tue Mar 24 2022 yangping <yangping69@huawei.com> - 1.22.2-5
|
||||
- delete %{?dist}
|
||||
* Fri Jul 15 2022 longcheng <longcheng@kylinos.com.cn> - 1.22.2-6
|
||||
- KYOS-F: changed font and document font to Noto
|
||||
- KYOS-F: Add api to check hotplug_mode_update property for outputs
|
||||
- KYOS-F: Fix mate-settings-daemon crash
|
||||
- KYOS-F: Add the gdk window scale settings
|
||||
- KYOS-F: Add lockdown settings for reboot and suspend (#29094)
|
||||
- KYOS-F: Fix virtual screens not recognized
|
||||
- KYOS-B: Add Requires: google-noto-sans-cjk-sc-fonts
|
||||
|
||||
* Tue Jun 14 2022 tanyulong <tanyulong@kylinos.cn> - 1.22.2-5
|
||||
- Remove the release suffix
|
||||
|
||||
* Tue Jan 25 2022 longcheng <longcheng@kylinos.com.cn> - 1.22.2-4
|
||||
- Modify the require isoft-menus to openEuler-menus
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user