Compare commits

1 Commits
main ... 1.1

3 changed files with 29 additions and 38 deletions

View File

@@ -1,8 +1,6 @@
Index: libglade-2.6.4/libglade-convert.in
===================================================================
--- libglade-2.6.4.orig/libglade-convert.in
+++ libglade-2.6.4/libglade-convert.in
@@ -45,7 +45,7 @@ class WidgetDef:
--- libglade-convert.in (original)
+++ libglade-convert.in (refactored)
@@ -45,7 +45,7 @@
if name == 'class':
self.wclass = value
return
@@ -11,7 +9,7 @@ Index: libglade-2.6.4/libglade-convert.in
self.property_names.remove(name)
del self.properties[name]
if value == 'True': value = 'yes'
@@ -53,19 +53,19 @@ class WidgetDef:
@@ -53,19 +53,19 @@
self.property_names.append(name)
self.properties[name] = value
def __delitem__(self, name):
@@ -35,7 +33,7 @@ Index: libglade-2.6.4/libglade-convert.in
self.property_names.remove(name)
del self.properties[name]
@@ -85,7 +85,7 @@ class WidgetDef:
@@ -85,7 +85,7 @@
def __getitem__(self, name):
return self.properties[name]
def __setitem__(self, name, value):
@@ -44,7 +42,7 @@ Index: libglade-2.6.4/libglade-convert.in
self.property_names.remove(name)
del self.properties[name]
if value == 'True': value = 'yes'
@@ -93,19 +93,19 @@ class WidgetDef:
@@ -93,19 +93,19 @@
self.property_names.append(name)
self.properties[name] = value
def __delitem__(self, name):
@@ -68,7 +66,7 @@ Index: libglade-2.6.4/libglade-convert.in
self.property_names.remove(name)
del self.properties[name]
@@ -114,27 +114,27 @@ class WidgetDef:
@@ -114,27 +114,27 @@
return
if self.internal_child:
@@ -105,7 +103,7 @@ Index: libglade-2.6.4/libglade-convert.in
def add_child(self, widget, internal_child=None):
child = self.ChildDef(widget, internal_child)
@@ -142,7 +142,7 @@ class WidgetDef:
@@ -142,7 +142,7 @@
return child
def dump(self, indent):
@@ -114,7 +112,7 @@ Index: libglade-2.6.4/libglade-convert.in
want_newline = 0
for name in self.property_names:
attrs = ''
@@ -154,41 +154,41 @@ class WidgetDef:
@@ -154,41 +154,41 @@
attrs += ' translatable="yes"'
if name[:3] == 'cxx':
attrs += ' agent="glademm"'
@@ -171,7 +169,7 @@ Index: libglade-2.6.4/libglade-convert.in
def handle_signal(widget, signalnode):
name = None
@@ -414,7 +414,7 @@ parent_table = {
@@ -414,7 +414,7 @@
global_group_map = { }
def find_parent(type):
@@ -180,7 +178,7 @@ Index: libglade-2.6.4/libglade-convert.in
return parent_table[type]
return ''
@@ -585,7 +585,7 @@ stock_menu_items = {
@@ -585,7 +585,7 @@
'GNOMEUIINFO_MENU_GAME_TREE': (0, '_Game'),
}
def stock_menu_translate(old_name):
@@ -189,7 +187,7 @@ Index: libglade-2.6.4/libglade-convert.in
return stock_menu_items[old_name]
else:
return (0, old_name)
@@ -598,7 +598,7 @@ def translate_color (color):
@@ -598,7 +598,7 @@
def fixup_as_type(widget, type):
if verbose:
@@ -198,7 +196,7 @@ Index: libglade-2.6.4/libglade-convert.in
# table based property removals/renames
for name in global_obsolete_props:
@@ -606,11 +606,11 @@ def fixup_as_type(widget, type):
@@ -606,11 +606,11 @@
for old, new in global_renamed_props:
widget.rename_prop(old, new)
@@ -212,7 +210,7 @@ Index: libglade-2.6.4/libglade-convert.in
for old, new in renamed_props[type]:
widget.rename_prop(old, new)
@@ -618,12 +618,12 @@ def fixup_as_type(widget, type):
@@ -618,12 +618,12 @@
for childdef in widget.children:
childdef.rename_prop(old, new)
@@ -227,7 +225,7 @@ Index: libglade-2.6.4/libglade-convert.in
for old, new in renamed_child_props[type]:
for childdef in widget.children:
childdef.rename_prop(old, new)
@@ -689,8 +689,8 @@ def fixup_as_type(widget, type):
@@ -689,8 +689,8 @@
del childdef.widget['child_name']
childdef['type'] = 'tab'
else:
@@ -238,7 +236,7 @@ Index: libglade-2.6.4/libglade-convert.in
if type == 'GtkFileSelection':
for childdef in widget.children:
@@ -775,8 +775,7 @@ def fixup_as_type(widget, type):
@@ -775,8 +775,7 @@
del childdef.widget['child_name']
try:
@@ -248,7 +246,7 @@ Index: libglade-2.6.4/libglade-convert.in
except IndexError:
return 0
childdef.widget['class'] = 'GtkHButtonBox'
@@ -791,8 +790,7 @@ def fixup_as_type(widget, type):
@@ -791,8 +790,7 @@
del childdef.widget['child_name']
try:
@@ -258,7 +256,7 @@ Index: libglade-2.6.4/libglade-convert.in
except IndexError:
return 0
childdef.widget['class'] = 'GtkHButtonBox'
@@ -881,7 +879,7 @@ def fixup_as_type(widget, type):
@@ -881,7 +879,7 @@
# have the glade id of the root group widget.
if type == 'GtkRadioButton' or type == 'GtkRadioMenuItem':
if widget.has_prop ('group'):
@@ -267,7 +265,7 @@ Index: libglade-2.6.4/libglade-convert.in
widget['group'] = global_group_map[widget['group']]
else:
global_group_map[widget['group']] = widget['name']
@@ -898,7 +896,7 @@ def fixup_as_type(widget, type):
@@ -898,7 +896,7 @@
elif childdef.widget['class'] == 'GtkRadioButton':
childdef.widget['class'] = 'radio'
if childdef.widget.has_prop('group'):
@@ -276,7 +274,7 @@ Index: libglade-2.6.4/libglade-convert.in
childdef.widget['group'] = global_group_map[childdef.widget['group']]
else:
global_group_map[childdef.widget['group']] = childdef.widget['name']
@@ -1135,8 +1133,8 @@ bad_widgets = {
@@ -1135,8 +1133,8 @@
def check_widget(widget, requirelist=[]):
try:
error = bad_widgets[widget['class']]
@@ -287,7 +285,7 @@ Index: libglade-2.6.4/libglade-convert.in
if error == 'removed':
widget.mark_obsolete ()
except KeyError:
@@ -1171,21 +1169,21 @@ def handle_file(filename):
@@ -1171,21 +1169,21 @@
fixup_widget(widgetdef)
check_widget(widgetdef, requireslist)
@@ -316,7 +314,7 @@ Index: libglade-2.6.4/libglade-convert.in
document.unlink() # only needed for python interpreters without cyclic gc
usage = 'usage: libglade-convert [--no-upgrade] [--verbose] oldfile.glade'
@@ -1201,10 +1199,10 @@ def main():
@@ -1201,10 +1199,10 @@
elif opt == '--verbose':
verbose = 1
elif opt == '--help':

View File

@@ -1,14 +1,3 @@
-------------------------------------------------------------------
Thu Apr 11 07:13:20 UTC 2024 - pgajdos@suse.com
- remove dependency on /usr/bin/python3 using
%python3_fix_shebang macro, [bsc#1212476]
-------------------------------------------------------------------
Tue Nov 28 10:57:58 UTC 2023 - Dominique Leuenberger <dimstar@opensuse.org>
- Use %autosetup instead of %setup/%patch.
-------------------------------------------------------------------
Mon Dec 19 08:39:21 UTC 2022 - Dominique Leuenberger <dimstar@opensuse.org>

View File

@@ -1,7 +1,7 @@
#
# spec file for package libglade2
#
# Copyright (c) 2024 SUSE LLC
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -74,13 +74,16 @@ to compile and link applications that use libglade2.
Summary: Documentation for the Glade library
Group: Development/Libraries/GNOME
Requires: libglade-2_0-0 = %{version}
%if 0%{?suse_version} >= 1120
BuildArch: noarch
%endif
%description doc
This package contains documentation and examples for the Glade library.
%prep
%autosetup -n %{_name}-%{version} -p1
%setup -q -n %{_name}-%{version}
%patch0
%build
export PYTHON=%{_bindir}/python3
@@ -92,8 +95,9 @@ make %{?_smp_mflags}
%make_install
mkdir -p %{buildroot}%{_libdir}/libglade/2.0
find %{buildroot} -type f -name "*.la" -delete -print
%if 0%{?suse_version} > 1020
%fdupes %{buildroot}
%python3_fix_shebang
%endif
%post -n libglade-2_0-0 -p /sbin/ldconfig
%postun -n libglade-2_0-0 -p /sbin/ldconfig