50 .inst_prefix =
nullptr,
51 .autoinstall =
nullptr
62#define ML_COL_SUBTYPE 4
70#define ML_STORE_SIZE 9
72#define FC_TYPE_MPROW (fc_mprow_get_type())
178 const char *
buttons[] = {
_(
"Quit"),
_(
"Cancel"),
nullptr };
181 "Are you sure you want to quit?"));
364 _(
"Another download already active"));
377 _(
"Failed to start downloader"));
427 if (
row !=
nullptr) {
429 row->notes ==
nullptr ?
"-" :
row->notes);
431 if (
row->notes !=
nullptr) {
453 const char *version,
const char *
license,
472 row->lic =
Q_(
"?license:Unknown");
476 if (
row->inst ==
nullptr) {
477 row->inst =
_(
"Not installed");
482 row->subtype = subtype;
519 const char *
str =
"-";
715 _(
"Freeciv modpack installer (gtk4x)"));
719#ifndef FREECIV_MSWINDOWS
779 log_fatal(
_(
"Failed to open graphical mode."));
static struct ai_type * self
const char * download_modpack(const char *URL, const struct fcmp_params *fcmp, dl_msg_callback mcb, dl_pb_callback pbcb)
const char * download_modpack_list(const struct fcmp_params *fcmp, modpack_list_setup_cb cb, dl_msg_callback mcb)
bool is_option(const char *option_name, char *option)
void cmdline_option_values_free(void)
void fc_fprintf(FILE *stream, const char *format,...) fc__attribute((__format__(__printf__
#define log_verbose(message,...)
#define log_fatal(message,...)
#define log_debug(message,...)
void load_install_info_lists(struct fcmp_params *fcmp)
#define DEFAULT_URL_START
int fcmp_parse_cmdline(int argc, char *argv[])
const char * mpdb_installed_version(const char *name, enum modpack_type type)
static void msg_dl_thread(const char *msg)
int main(int argc, char *argv[])
static gboolean quit_dialog_callback(void)
static GtkWidget * statusbar
static GListStore * main_store
static gboolean query_main_list_tooltip_cb(GtkWidget *widget, gint x, gint y, gboolean keyboard_tip, GtkTooltip *tooltip, gpointer data)
static void selection_change(GtkSelectionModel *model, guint position, guint n_items, gpointer user_data)
static FcMPRow * fc_mprow_new(void)
static gboolean versionlist_update_main_thread(gpointer user_data)
static void activate_gui(GtkApplication *app, gpointer data)
static GtkWidget * toplevel
static void modinst_quit(void)
static void pbar_callback(int downloaded, int max)
static void URL_return(GtkEntry *w, gpointer data)
static GtkWidget * URL_input
static void fc_mprow_class_init(FcMPRowClass *klass)
static void fc_mprow_finalize(GObject *gobject)
static gboolean downloading
static GtkWidget * progressbar
static void gui_download_modpack(const char *URL)
static gboolean msg_main_thread(gpointer user_data)
static void fc_mprow_init(FcMPRow *self)
static void install_clicked(GtkWidget *w, gpointer data)
static GtkAlertDialog * quit_dialog
static void factory_bind(GtkSignalListItemFactory *self, GtkListItem *list_item, gpointer user_data)
static void setup_modpack_list(const char *name, const char *URL, const char *version, const char *license, enum modpack_type type, const char *subtype, const char *notes)
static GtkApplication * fcmp_app
static void pbar_dl_thread(int current, int max)
static void msg_callback(const char *msg)
static GtkWidget * main_list
static void quit_dialog_response(GObject *dialog, GAsyncResult *result, gpointer data)
static void modinst_setup_widgets(void)
static void versionlist_update_dl_thread(void)
static gboolean pbar_main_thread(gpointer user_data)
static void factory_setup(GtkSignalListItemFactory *self, GtkListItem *list_item, gpointer user_data)
static gpointer download_thread(gpointer data)
GObjectClass parent_class
int fc_snprintf(char *str, size_t n, const char *format,...)
const char * fc_git_revision(void)
const char * word_version(void)