Fixes python3-gobject warning in setup dialog
This commit is contained in:
parent
3ccdd30a9a
commit
cc6d411f22
@ -21,3 +21,52 @@ index dcd2e3f..295adc5 100644
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (triggered) {
|
if (triggered) {
|
||||||
|
From c346468fdf9ef8f7f6c8acd0dc54b976b1dafd14 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Peng Wu <alexepico@gmail.com>
|
||||||
|
Date: Tue, 29 Sep 2020 11:33:27 +0800
|
||||||
|
Subject: [PATCH] Fixes import/export dictionary in setup dialog
|
||||||
|
|
||||||
|
---
|
||||||
|
setup/main2.py | 19 +++++++++++--------
|
||||||
|
1 file changed, 11 insertions(+), 8 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/setup/main2.py b/setup/main2.py
|
||||||
|
index adbebe9..f2d5847 100644
|
||||||
|
--- a/setup/main2.py
|
||||||
|
+++ b/setup/main2.py
|
||||||
|
@@ -435,10 +435,11 @@ class PreferencesDialog:
|
||||||
|
|
||||||
|
def __import_dictionary_cb(self, widget):
|
||||||
|
dialog = Gtk.FileChooserDialog \
|
||||||
|
- (_("Please choose a file"), self.__dialog,
|
||||||
|
- Gtk.FileChooserAction.OPEN,
|
||||||
|
- (Gtk.STOCK_CANCEL, Gtk.ResponseType.CANCEL,
|
||||||
|
- Gtk.STOCK_OPEN, Gtk.ResponseType.OK))
|
||||||
|
+ (title = _("Please choose a file"), parent = self.__dialog,
|
||||||
|
+ action = Gtk.FileChooserAction.OPEN)
|
||||||
|
+
|
||||||
|
+ dialog.add_buttons(Gtk.STOCK_CANCEL, Gtk.ResponseType.CANCEL,
|
||||||
|
+ Gtk.STOCK_OPEN, Gtk.ResponseType.OK)
|
||||||
|
|
||||||
|
filter_text = Gtk.FileFilter()
|
||||||
|
filter_text.set_name("Text files")
|
||||||
|
@@ -453,10 +454,12 @@ class PreferencesDialog:
|
||||||
|
|
||||||
|
def __export_dictionary_cb(self, widget):
|
||||||
|
dialog = Gtk.FileChooserDialog \
|
||||||
|
- (_("Please save a file"), self.__dialog,
|
||||||
|
- Gtk.FileChooserAction.SAVE,
|
||||||
|
- (Gtk.STOCK_CANCEL, Gtk.ResponseType.CANCEL,
|
||||||
|
- Gtk.STOCK_SAVE, Gtk.ResponseType.OK))
|
||||||
|
+ (title = _("Please save a file"), parent = self.__dialog,
|
||||||
|
+ action = Gtk.FileChooserAction.SAVE)
|
||||||
|
+
|
||||||
|
+ dialog.add_buttons(Gtk.STOCK_CANCEL, Gtk.ResponseType.CANCEL,
|
||||||
|
+ Gtk.STOCK_SAVE, Gtk.ResponseType.OK)
|
||||||
|
+
|
||||||
|
dialog.set_do_overwrite_confirmation(True)
|
||||||
|
|
||||||
|
filter_text = Gtk.FileFilter()
|
||||||
|
--
|
||||||
|
2.26.2
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
Name: ibus-libpinyin
|
Name: ibus-libpinyin
|
||||||
Version: 1.11.93
|
Version: 1.11.93
|
||||||
Release: 2%{?dist}
|
Release: 3%{?dist}
|
||||||
Summary: Intelligent Pinyin engine based on libpinyin for IBus
|
Summary: Intelligent Pinyin engine based on libpinyin for IBus
|
||||||
License: GPLv3+
|
License: GPLv3+
|
||||||
URL: https://github.com/libpinyin/ibus-libpinyin
|
URL: https://github.com/libpinyin/ibus-libpinyin
|
||||||
@ -88,6 +88,9 @@ desktop-file-validate $RPM_BUILD_ROOT%{_datadir}/applications/ibus-setup-libbopo
|
|||||||
%{_datadir}/ibus/component/*
|
%{_datadir}/ibus/component/*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Oct 12 2020 Peng Wu <pwu@redhat.com> - 1.11.93-3
|
||||||
|
- Fixes python3-gobject warning in setup dialog
|
||||||
|
|
||||||
* Sun Sep 27 2020 Peng Wu <pwu@redhat.com> - 1.11.93-2
|
* Sun Sep 27 2020 Peng Wu <pwu@redhat.com> - 1.11.93-2
|
||||||
- Fixes Shift key switch issue
|
- Fixes Shift key switch issue
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user