MidoriExtension* extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Advertisement blocker"),
"description", _("Block advertisements according to a filter list"),
- "version", "0.5",
+ "version", "0.5" MIDORI_VERSION_SUFFIX,
"authors", "Christian Dywan <christian@twotoasts.de>",
NULL);
midori_extension_install_string_list (extension, "filters", NULL, G_MAXSIZE);
MidoriExtension* extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("User addons"),
"description", _("Support for userscripts and userstyles"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "Arno Renevier <arno@renevier.net>",
NULL);
g_signal_connect (extension, "activate",
MidoriExtension* extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Colorful Tabs"),
"description", _("Tint each tab distinctly"),
- "version", "0.5",
+ "version", "0.5" MIDORI_VERSION_SUFFIX,
"authors", "Christian Dywan <christian@twotoasts.de>, Samuel Creshal <creshal@arcor.de>",
NULL);
MidoriExtension *extension = g_object_new(MIDORI_TYPE_EXTENSION,
"name", _("Cookie Manager"),
"description", _("List, view and delete cookies"),
- "version", "0.2",
+ "version", "0.2" MIDORI_VERSION_SUFFIX,
"authors", "Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>",
NULL);
MidoriExtension* extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Copy Addresses of Tabs"),
"description", _("Copy the addresses of all tabs to the clipboard"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "MonkeyOfDoom <pixelmonkey@ensellitis.com>",
NULL);
extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Feed Panel"),
"description", _("Read Atom/ RSS feeds"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "Dale Whittaker <dayul@users.sf.net>",
NULL);
if (formhistory_prepare_js ())
{
- ver = "1.0";
+ ver = "1.0" MIDORI_VERSION_SUFFIX;
desc = g_strdup (_("Stores history of entered form data"));
}
else
internal Manager () {
GLib.Object (name: _("History List"),
description: _("Move to the last used tab when switching or closing tabs"),
- version: "0.4",
+ version: "0.4" + Midori.VERSION_SUFFIX,
authors: "André Stösel <andre@stoesel.de>");
this.install_integer ("TabClosingBehavior", TabClosingBehavior.LAST);
MidoriExtension* extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Mouse Gestures"),
"description", _("Control Midori by moving the mouse"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "Matthias Kruk <mkruk@matthiaskruk.de>", NULL);
midori_extension_install_integer (extension, "button", MOUSE_BUTTON_RIGHT);
MidoriExtension* extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Shortcuts"),
"description", _("View and edit keyboard shortcuts"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "Christian Dywan <christian@twotoasts.de>",
NULL);
MidoriExtension* extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Statusbar Clock"),
"description", _("Display date and time in the statusbar"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "Arno Renevier <arno@renevier.net>",
NULL);
midori_extension_install_string (extension, "format", DEFAULT_FORMAT);
MidoriExtension* extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Statusbar Features"),
"description", _("Easily toggle features on web pages on and off"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "Christian Dywan <christian@twotoasts.de>",
NULL);
extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Tab Panel"),
"description", _("Show tabs in a vertical panel"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "Christian Dywan <christian@twotoasts.de>",
NULL);
MidoriExtension* extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Only Icons on Tabs by default"),
"description", _("New tabs have no label by default"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "MonkeyOfDoom <pixelmonkey@ensellitis.com>",
NULL);
MidoriExtension* extension = g_object_new(MIDORI_TYPE_EXTENSION,
"name", _("Toolbar Editor"),
"description", _("Easily edit the toolbar layout"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>",
NULL);
MidoriExtension* extension = g_object_new (MIDORI_TYPE_EXTENSION,
"name", _("Web Cache"),
"description", _("Cache HTTP communication on disk"),
- "version", "0.1",
+ "version", "0.1" MIDORI_VERSION_SUFFIX,
"authors", "Christian Dywan <christian@twotoasts.de>",
NULL);
katze_assign (extension->priv->description, g_value_dup_string (value));
break;
case PROP_VERSION:
- katze_assign (extension->priv->version, g_value_dup_string (value));
+ {
+ /* Don't show version suffix if it matches the running Midori */
+ const gchar* version = g_value_get_string (value);
+ if (g_str_has_suffix (version, MIDORI_VERSION_SUFFIX))
+ katze_assign (extension->priv->version,
+ g_strndup (version,
+ strlen (version) - strlen (MIDORI_VERSION_SUFFIX)));
+ /* No version suffix at all, must be 0.4.1 or 0.4.1 git */
+ else if (!strchr (version, '-') && !strchr (version, '('))
+ katze_assign (extension->priv->version,
+ g_strconcat (version, " (0.4.1)", NULL));
+ else
+ katze_assign (extension->priv->version, g_strdup (version));
break;
+ }
case PROP_AUTHORS:
katze_assign (extension->priv->authors, g_value_dup_string (value));
break;
[CCode (cprefix = "Midori", lower_case_cprefix = "midori_")]
namespace Midori {
+ public const string VERSION_SUFFIX;
+
[CCode (cheader_filename = "midori/midori.h")]
public class App : GLib.Object {
public App ();
APPNAME = 'midori'
VERSION = VERSION_FULL = str (major) + '.' + str (minor) + '.' + str (micro)
+VERSION_SUFFIX = ' (%s)' % VERSION
try:
if os.path.isdir ('.git'):
git = Utils.cmd_output (['git', 'describe'], silent=True)
if git:
VERSION_FULL = git.strip ()
+ VERSION_SUFFIX = VERSION_FULL.replace (VERSION, '')
except:
pass
if debug_level == 'full':
conf.define ('PACKAGE_VERSION', '%s (debug)' % VERSION_FULL)
+ conf.env.append_value ('CCFLAGS', '-DMIDORI_VERSION_SUFFIX="%s (debug)"' % VERSION_SUFFIX)
else:
conf.define ('PACKAGE_VERSION', VERSION_FULL)
+ conf.env.append_value ('CCFLAGS', '-DMIDORI_VERSION_SUFFIX="%s"' % VERSION_SUFFIX)
conf.write_config_header ('config.h')
if compiler == 'gcc':