gtkappchooserwidget: Remove deprecations

It's worth keeping and used by several projects. In the next
commit we'll port to GtkListView.
This commit is contained in:
Corey Berla
2024-10-12 18:07:48 -07:00
parent 06b8863bf7
commit 526f230a51
6 changed files with 24 additions and 53 deletions

View File

@@ -2,7 +2,6 @@ gtk_deprecated_sources = [
'deprecated/gtkappchooser.c',
'deprecated/gtkappchooserbutton.c',
'deprecated/gtkappchooserdialog.c',
'deprecated/gtkappchooserwidget.c',
'deprecated/gtkassistant.c',
'deprecated/gtkcellarea.c',
'deprecated/gtkcellareabox.c',
@@ -56,7 +55,6 @@ gtk_deprecated_headers = [
'deprecated/gtkappchooser.h',
'deprecated/gtkappchooserbutton.h',
'deprecated/gtkappchooserdialog.h',
'deprecated/gtkappchooserwidget.h',
'deprecated/gtkassistant.h',
'deprecated/gtkcellarea.h',
'deprecated/gtkcellareabox.h',

View File

@@ -41,7 +41,7 @@
#include <gtk/gtkalertdialog.h>
#include <gtk/deprecated/gtkappchooser.h>
#include <gtk/deprecated/gtkappchooserdialog.h>
#include <gtk/deprecated/gtkappchooserwidget.h>
#include <gtk/gtkappchooserwidget.h>
#include <gtk/deprecated/gtkappchooserbutton.h>
#include <gtk/gtkapplication.h>
#include <gtk/gtkapplicationwindow.h>

View File

@@ -26,13 +26,15 @@
#include "gtkappchooserwidget.h"
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
#include "gtkmarshalers.h"
#include "gtkappchooserwidget.h"
#include "gtkappchooserprivate.h"
#include "gtkliststore.h"
#include "gtktreeview.h"
#include "gtktreeselection.h"
#include "gtktreemodelsort.h"
#include "deprecated/gtkappchooserprivate.h"
#include "deprecated/gtkliststore.h"
#include "deprecated/gtktreeview.h"
#include "deprecated/gtktreeselection.h"
#include "deprecated/gtktreemodelsort.h"
#include "gtkorientable.h"
#include "gtkscrolledwindow.h"
#include "gtklabel.h"
@@ -44,7 +46,6 @@
#include <glib/gi18n-lib.h>
#include <gio/gio.h>
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
/**
* GtkAppChooserWidget:
@@ -72,10 +73,6 @@ G_GNUC_BEGIN_IGNORE_DEPRECATIONS
* ## CSS nodes
*
* `GtkAppChooserWidget` has a single CSS node with name appchooser.
*
* Deprecated: 4.10: The application selection widgets should be
* implemented according to the design of each platform and/or
* application requiring them.
*/
typedef struct _GtkAppChooserWidgetClass GtkAppChooserWidgetClass;
@@ -1118,8 +1115,6 @@ gtk_app_chooser_widget_iface_init (GtkAppChooserIface *iface)
* that can handle content of the given type.
*
* Returns: a newly created `GtkAppChooserWidget`
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
GtkWidget *
gtk_app_chooser_widget_new (const char *content_type)
@@ -1136,8 +1131,6 @@ gtk_app_chooser_widget_new (const char *content_type)
*
* Sets whether the app chooser should show the default handler
* for the content type in a separate section.
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
void
gtk_app_chooser_widget_set_show_default (GtkAppChooserWidget *self,
@@ -1163,8 +1156,6 @@ gtk_app_chooser_widget_set_show_default (GtkAppChooserWidget *self,
* for the content type in a separate section.
*
* Returns: the value of [property@Gtk.AppChooserWidget:show-default]
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
gboolean
gtk_app_chooser_widget_get_show_default (GtkAppChooserWidget *self)
@@ -1181,8 +1172,6 @@ gtk_app_chooser_widget_get_show_default (GtkAppChooserWidget *self)
*
* Sets whether the app chooser should show recommended applications
* for the content type in a separate section.
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
void
gtk_app_chooser_widget_set_show_recommended (GtkAppChooserWidget *self,
@@ -1208,8 +1197,6 @@ gtk_app_chooser_widget_set_show_recommended (GtkAppChooserWidget *self,
* for the content type in a separate section.
*
* Returns: the value of [property@Gtk.AppChooserWidget:show-recommended]
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
gboolean
gtk_app_chooser_widget_get_show_recommended (GtkAppChooserWidget *self)
@@ -1226,8 +1213,6 @@ gtk_app_chooser_widget_get_show_recommended (GtkAppChooserWidget *self)
*
* Sets whether the app chooser should show related applications
* for the content type in a separate section.
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
void
gtk_app_chooser_widget_set_show_fallback (GtkAppChooserWidget *self,
@@ -1253,8 +1238,6 @@ gtk_app_chooser_widget_set_show_fallback (GtkAppChooserWidget *self,
* for the content type in a separate section.
*
* Returns: the value of [property@Gtk.AppChooserWidget:show-fallback]
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
gboolean
gtk_app_chooser_widget_get_show_fallback (GtkAppChooserWidget *self)
@@ -1271,8 +1254,6 @@ gtk_app_chooser_widget_get_show_fallback (GtkAppChooserWidget *self)
*
* Sets whether the app chooser should show applications
* which are unrelated to the content type.
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
void
gtk_app_chooser_widget_set_show_other (GtkAppChooserWidget *self,
@@ -1298,8 +1279,6 @@ gtk_app_chooser_widget_set_show_other (GtkAppChooserWidget *self,
* which are unrelated to the content type.
*
* Returns: the value of [property@Gtk.AppChooserWidget:show-other]
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
gboolean
gtk_app_chooser_widget_get_show_other (GtkAppChooserWidget *self)
@@ -1316,8 +1295,6 @@ gtk_app_chooser_widget_get_show_other (GtkAppChooserWidget *self)
*
* Sets whether the app chooser should show all applications
* in a flat list.
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
void
gtk_app_chooser_widget_set_show_all (GtkAppChooserWidget *self,
@@ -1343,8 +1320,6 @@ gtk_app_chooser_widget_set_show_all (GtkAppChooserWidget *self,
* in a flat list.
*
* Returns: the value of [property@Gtk.AppChooserWidget:show-all]
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
gboolean
gtk_app_chooser_widget_get_show_all (GtkAppChooserWidget *self)
@@ -1361,8 +1336,6 @@ gtk_app_chooser_widget_get_show_all (GtkAppChooserWidget *self)
*
* Sets the text that is shown if there are not applications
* that can handle the content type.
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
void
gtk_app_chooser_widget_set_default_text (GtkAppChooserWidget *self,
@@ -1389,8 +1362,6 @@ gtk_app_chooser_widget_set_default_text (GtkAppChooserWidget *self,
* that can handle the content type.
*
* Returns: (nullable): the value of [property@Gtk.AppChooserWidget:default-text]
*
* Deprecated: 4.10: This widget will be removed in GTK 5
*/
const char *
gtk_app_chooser_widget_get_default_text (GtkAppChooserWidget *self)

View File

@@ -42,43 +42,43 @@ typedef struct _GtkAppChooserWidget GtkAppChooserWidget;
GDK_AVAILABLE_IN_ALL
GType gtk_app_chooser_widget_get_type (void) G_GNUC_CONST;
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
GtkWidget * gtk_app_chooser_widget_new (const char *content_type);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
void gtk_app_chooser_widget_set_show_default (GtkAppChooserWidget *self,
gboolean setting);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
gboolean gtk_app_chooser_widget_get_show_default (GtkAppChooserWidget *self);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
void gtk_app_chooser_widget_set_show_recommended (GtkAppChooserWidget *self,
gboolean setting);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
gboolean gtk_app_chooser_widget_get_show_recommended (GtkAppChooserWidget *self);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
void gtk_app_chooser_widget_set_show_fallback (GtkAppChooserWidget *self,
gboolean setting);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
gboolean gtk_app_chooser_widget_get_show_fallback (GtkAppChooserWidget *self);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
void gtk_app_chooser_widget_set_show_other (GtkAppChooserWidget *self,
gboolean setting);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
gboolean gtk_app_chooser_widget_get_show_other (GtkAppChooserWidget *self);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
void gtk_app_chooser_widget_set_show_all (GtkAppChooserWidget *self,
gboolean setting);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
gboolean gtk_app_chooser_widget_get_show_all (GtkAppChooserWidget *self);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
void gtk_app_chooser_widget_set_default_text (GtkAppChooserWidget *self,
const char *text);
GDK_DEPRECATED_IN_4_10
GDK_AVAILABLE_IN_ALL
const char * gtk_app_chooser_widget_get_default_text (GtkAppChooserWidget *self);
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GtkAppChooserWidget, g_object_unref)

View File

@@ -164,6 +164,7 @@ gtk_public_sources = files([
'gtkactionbar.c',
'gtkadjustment.c',
'gtkalertdialog.c',
'gtkappchooserwidget.c',
'gtkapplication.c',
'gtkapplicationwindow.c',
'gtkaspectframe.c',
@@ -429,6 +430,7 @@ gtk_public_headers = files([
'gtkactionbar.h',
'gtkadjustment.h',
'gtkalertdialog.h',
'gtkappchooserwidget.h',
'gtkapplication.h',
'gtkapplicationwindow.h',
'gtkaspectframe.h',

View File

@@ -68,7 +68,6 @@ gtk/css/gtkcssdataurl.c
gtk/deprecated/gtkappchooserbutton.c
gtk/deprecated/gtkappchooser.c
gtk/deprecated/gtkappchooserdialog.c
gtk/deprecated/gtkappchooserwidget.c
gtk/deprecated/gtkassistant.c
gtk/deprecated/gtkcellareabox.c
gtk/deprecated/gtkcellarea.c
@@ -118,6 +117,7 @@ gtk/gtkactionbar.c
gtk/gtkactionmuxer.c
gtk/gtkadjustment.c
gtk/gtkalertdialog.c
gtk/gtkappchooserwidget.c
gtk/gtkapplication.c
gtk/gtkapplication-dbus.c
gtk/gtkapplication-quartz.c