Convert to constants.
namespace
{
+constexpr gint SIDEBAR_DEFAULT_WIDTH = 250;
+
void remove_child_from_parent(gpointer data)
{
gtk_container_remove(GTK_CONTAINER(gtk_widget_get_parent(GTK_WIDGET(data))), GTK_WIDGET(data));
}
-}
+} // namespace
struct KnownPanes
{
#include "utilops.h"
#include "view-file.h"
+namespace
+{
+
+constexpr gint IMAGE_MIN_WIDTH = 100;
+
+} // namespace
+
static GtkWidget *layout_image_pop_menu(LayoutWindow *lw);
static void layout_image_set_buttons(LayoutWindow *lw);
static gboolean layout_image_animate_new_file(LayoutWindow *lw);
#define GQ_COLLECTION_EXT ".gqv"
+// @todo Merge with PixbufRendererScrollResetType ?
#define SCROLL_RESET_TOPLEFT 0
#define SCROLL_RESET_CENTER 1
#define SCROLL_RESET_NOCHANGE 2
+// @todo Deduplicate mousewheel_scrolls processing
#define MOUSEWHEEL_SCROLL_SIZE 20
#define GQ_DEFAULT_SHELL_PATH "/bin/sh"
#define GQ_DEFAULT_SHELL_OPTIONS "-c"
-#define DEFAULT_THUMB_WIDTH 96
-#define DEFAULT_THUMB_HEIGHT 72
-
#define DEFAULT_MINIMAL_WINDOW_SIZE 100
-#define IMAGE_MIN_WIDTH 100
-#define SIDEBAR_DEFAULT_WIDTH 250
-
#define DEFAULT_OVERLAY_INFO "%collection:<i>*</i>\\n%" \
"(%number%/%total%) [%zoom%] <b>%name%</b>\n" \
#include "ui-bookmark.h"
#include "ui-fileops.h"
+namespace
+{
+
+constexpr gint DEFAULT_THUMB_WIDTH = 96;
+constexpr gint DEFAULT_THUMB_HEIGHT = 72;
+
+} // namespace
+
ConfOptions *options;
CommandLine *command_line;
options->thumbnails.cache_into_dirs = FALSE;
options->thumbnails.enable_caching = TRUE;
- options->thumbnails.max_height = DEFAULT_THUMB_HEIGHT;
options->thumbnails.max_width = DEFAULT_THUMB_WIDTH;
+ options->thumbnails.max_height = DEFAULT_THUMB_HEIGHT;
options->thumbnails.quality = GDK_INTERP_TILES;
options->thumbnails.spec_standard = TRUE;
options->thumbnails.use_xvpics = TRUE;