Skip to content

Use XfceFilenameInput

A short while ago, a new widget, XfceFilenameInput, was added to libxfce4ui. This widget is designed to be a "smart" replacement for the GtkEnty widget, specifically designed for the entry of filenames. See commit 8f0ad0c23947545abf249aac56124cde74cdeb0a in libxfce4ui for details.

The first commit on this branch removes the whole thunar-create-dialog module from thunar, and replaces it with a single function in the thunar-dialogs module. I don't think that thunar-create-dialog needed to be an independent module, as its public interface really just consisted of a single function (which has been replaced by the new function in thunar-dialogs). The only reason there needed to be multiple functions to implement the create dialog was that a callback was used to check the validity of the entered text, and with XfceFilenameInput this is now redundant.

The second commit replaces the filename input functionality in the create dialog, the rename dialog, and the properties dialog with the new widget. This provides a unified implementation of filename entry rather than three separate ones. I have bumped the required libxfce4ui version to 4.15.1

Key points to note/for review:

  1. The only change I have made to the "autotools files" are removing the two lines for thunar-create-dialog.c/.h from Makefile.am. I have however added new #include statements to some files, but it builds ok, so I assume that automake handles all the dependency generation? (my autotools knowledge is exactly zero, sorry)
  2. Have I covered all of the places where thunar asks the user for a filename, or have I missed some?

Also, do let me know if I have done anything wrong/bad with the gitlab stuff. The new workflow has already caught some errors I made in an earlier version of this merge request, so I like it!

Comments and criticism are very welcome! Thanks!

Edited by Reuben Green

Merge request reports

Loading