Browse Source

NLS

SVN revision: 32632
enlightenment-0.17
Sebastian Dransfeld 15 years ago
parent
commit
c8c261f74a
  1. 2
      Makefile.am
  2. 3
      autogen.sh
  3. 116
      configure.in
  4. 2
      data/theme/Makefile.am
  5. 0
      po/LINGUAS
  6. 41
      po/Makevars
  7. 36
      po/POTFILES.in
  8. 22
      src/module/e_mod_main.c
  9. 2
      src/module/e_mod_main.h
  10. 24
      src/module/news_config.c
  11. 68
      src/module/news_config_dialog.c
  12. 12
      src/module/news_config_dialog_category.c
  13. 42
      src/module/news_config_dialog_feed.c
  14. 50
      src/module/news_config_dialog_feeds.c
  15. 26
      src/module/news_config_dialog_item.c
  16. 10
      src/module/news_config_dialog_item_content.c
  17. 8
      src/module/news_config_dialog_langs.c
  18. 20
      src/module/news_feed.c
  19. 16
      src/module/news_menu.c
  20. 6
      src/module/news_utils.h
  21. 4
      src/module/news_viewer.c

2
Makefile.am

@ -1,6 +1,6 @@
MAINTAINERCLEANFILES = Makefile.in
SUBDIRS = src data
SUBDIRS = src data po
filesdir = $(datadir)
files_DATA = module.desktop

3
autogen.sh

@ -3,7 +3,8 @@
rm -rf autom4te.cache
rm -f aclocal.m4 ltmain.sh
echo "Running aclocal..." ; aclocal $ACLOCAL_FLAGS || exit 1
echo "Running autopoint..." ; autopoint -f || :
echo "Running aclocal..." ; aclocal -I m4 $ACLOCAL_FLAGS || exit 1
echo "Running autoheader..." ; autoheader || exit 1
echo "Running autoconf..." ; autoconf || exit 1
echo "Running libtoolize..." ; (libtoolize --copy --automake || glibtoolize --automake) || exit 1

116
configure.in

@ -3,104 +3,61 @@ dnl Process this file with autoconf to produce a configure script.
# get rid of that stupid cache mechanism
rm -f config.cache
AC_INIT(news, 0.1.0, ooookiwi@gmail.com)
AC_PREREQ(2.59)
AC_INIT([news], [0.1.0], [ooookiwi@gmail.com])
AC_CONFIG_HEADERS(config.h)
AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE([1.8 foreign])
AC_CONFIG_SRCDIR(configure.in)
AC_CANONICAL_BUILD
AC_CANONICAL_HOST
AC_ISC_POSIX
AM_INIT_AUTOMAKE(1.6)
AM_CONFIG_HEADER(config.h)
AC_PROG_CC
AM_PROG_LIBTOOL
AM_PROG_CC_STDC
AC_HEADER_STDC
AC_C_CONST
ALL_LINGUAS="fi it ja ru sv"
AC_SUBST(ALL_LINGUAS)
define([AC_LIBTOOL_LANG_CXX_CONFIG], [:])dnl
define([AC_LIBTOOL_LANG_F77_CONFIG], [:])dnl
AC_PROG_LIBTOOL
AM_GNU_GETTEXT([external])
AM_GNU_GETTEXT_VERSION(0.14)
MODULE_ARCH="$host_os-$host_cpu"
AC_SUBST(MODULE_ARCH)
AC_DEFINE_UNQUOTED(MODULE_ARCH, "$MODULE_ARCH", "Module architecture")
AC_DEFINE_UNQUOTED(MODULE_VERSION, "0.1.0", "Module version")
# Check Library Directory
if test "x${libdir}" = 'x${exec_prefix}/lib'; then
if test "x${exec_prefix}" = "xNONE"; then
if test "x${prefix}" = "xNONE"; then
libdir="${ac_default_prefix}/lib";
else
libdir="${prefix}/lib";
fi
else
if test "x${prefix}" = "xNONE"; then
libdir="${ac_default_prefix}/lib";
else
libdir="${prefix}/lib";
fi
fi
fi
#
# Set Library Directory in config.h
#
if test "x${libdir}" = 'xNONE'; then
if test "x${prefix}" = "xNONE"; then
AC_DEFINE_UNQUOTED(PACKAGE_LIB_DIR, "${ac_default_prefix}/lib", "Package installed libraries destination")
else
AC_DEFINE_UNQUOTED(PACKAGE_LIB_DIR, "${prefix}/lib", "Package installed libraries destination")
fi
else
AC_DEFINE_UNQUOTED(PACKAGE_LIB_DIR, "${libdir}", "Package installed libraries destination")
fi
edje_cc="$(pkg-config --variable=prefix edje)/bin/edje_cc"
AC_ARG_WITH(edje-cc,
AC_HELP_STRING([--with-edje-cc=PATH], [specify a specific path to edje_cc]),
[
edje_cc=$withval;
echo " Enlightenment edje_cc explicitly set to "$edje_cc;
]
)
AC_SUBST(edje_cc)
#
# Set Data Directory in config.h
#
if test "x${prefix}" = "xNONE"; then
datadir="${HOME}/.e/e/modules/${PACKAGE}"
else
datadir="${libdir}/enlightenment/modules/${PACKAGE}"
fi
AC_DEFINE_UNQUOTED(PACKAGE_DATA_DIR, "${datadir}", "Package data destination")
#
# Set Data Root and Locale Directory in config.h
#
AC_PREFIX_DEFAULT(${HOME}/.e/e)
if test "x$prefix" = "xNONE"; then
datarootdir=${ac_default_prefix}
else
datarootdir=${prefix}/share
fi
localedir=${datarootdir}/locale
AC_SUBST(LOCALEDIR, "${localedir}")
AC_DEFINE_UNQUOTED(LOCALEDIR, "${localedir}", "Module Locale Directory")
#
# Check EFL Libs
#
PKG_CHECK_MODULES(EDJE, [edje >= 0.5.0])
AC_PATH_PROG(EDJE_CC, "edje_cc", "", $PATH)
#
# Check Enlightenment
#
AC_ARG_WITH(enlightenment-config,
[ --with-enlightenment-config=E_CONFIG use enlightenment-config specified ],
[
E_CONFIG=$withval;
echo "using "$E_CONFIG" for enlightenment-config";
],[
PROG="enlightenment-config";
AC_PATH_PROG(E_CONFIG, $PROG, "", $PATH)
])
AC_HELP_STRING([--with-enlightenment-config=E_CONFIG], [use enlightenment-config specified]),
[
E_CONFIG=$withval;
echo "using "$E_CONFIG" for enlightenment-config";
], [
PROG="enlightenment-config";
AC_PATH_PROG(E_CONFIG, $PROG, "", $PATH)
]
)
e_cflags=`$E_CONFIG --cflags`
e_libs=`$E_CONFIG --libs`
e_modules=`$E_CONFIG --module-dir`
AC_SUBST(e_cflags)
AC_SUBST(e_libs)
AC_SUBST(e_modules)
dnl TODO: Fix better install for homedir
datadir="${e_modules}/${PACKAGE}"
AC_OUTPUT([
e_modules-news.spec
@ -112,6 +69,7 @@ data/images/categories/Makefile
data/theme/Makefile
src/Makefile
src/module/Makefile
],[
po/Makefile.in
], [
])

2
data/theme/Makefile.am

@ -39,7 +39,7 @@ images/popup_warn_logo_error.png \
images/popup_warn_logo_info.png
e-module-news.edj: Makefile $(EXTRA_DIST)
$(EDJE_CC) $(EDJE_FLAGS) \
$(edje_cc) $(EDJE_FLAGS) \
$(top_srcdir)/data/theme/module.edc \
$(top_builddir)/data/theme/e-module-news.edj

0
po/LINGUAS

41
po/Makevars

@ -0,0 +1,41 @@
# Makefile variables for PO directory in any package using GNU gettext.
# Usually the message domain is the same as the package name.
DOMAIN = $(PACKAGE)
# These two variables depend on the location of this directory.
subdir = po
top_builddir = ..
# These options get passed to xgettext.
XGETTEXT_OPTIONS = --keyword=_ --keyword=N_ --from-code=UTF-8 --foreign-user
# This is the copyright holder that gets inserted into the header of the
# $(DOMAIN).pot file. Set this to the copyright holder of the surrounding
# package. (Note that the msgstr strings, extracted from the package's
# sources, belong to the copyright holder of the package.) Translators are
# expected to transfer the copyright for their translations to this person
# or entity, or to disclaim their copyright. The empty string stands for
# the public domain; in this case the translators are expected to disclaim
# their copyright.
COPYRIGHT_HOLDER = Enlightenment development team
# This is the email address or URL to which the translators shall report
# bugs in the untranslated strings:
# - Strings which are not entire sentences, see the maintainer guidelines
# in the GNU gettext documentation, section 'Preparing Strings'.
# - Strings which use unclear terms or require additional context to be
# understood.
# - Strings which make invalid assumptions about notation of date, time or
# money.
# - Pluralisation problems.
# - Incorrect English spelling.
# - Incorrect formatting.
# It can be your email address, or a mailing list address where translators
# can write to without being subscribed, or the URL of a web page through
# which the translators can contact you.
MSGID_BUGS_ADDRESS = enlightenment-devel@lists.sourceforge.net
# This is the list of locale categories, beyond LC_MESSAGES, for which the
# message catalogs shall be used. It is usually empty.
EXTRA_LOCALE_CATEGORIES =

36
po/POTFILES.in

@ -0,0 +1,36 @@
src/module/News.h
src/module/News_includes.h
src/module/e_mod_main.c
src/module/e_mod_main.h
src/module/news_config.c
src/module/news_config.h
src/module/news_config_dialog.c
src/module/news_config_dialog.h
src/module/news_config_dialog_category.c
src/module/news_config_dialog_category.h
src/module/news_config_dialog_feed.c
src/module/news_config_dialog_feed.h
src/module/news_config_dialog_feeds.c
src/module/news_config_dialog_feeds.h
src/module/news_config_dialog_item.c
src/module/news_config_dialog_item.h
src/module/news_config_dialog_item_content.c
src/module/news_config_dialog_item_content.h
src/module/news_config_dialog_langs.c
src/module/news_config_dialog_langs.h
src/module/news_feed.c
src/module/news_feed.h
src/module/news_item.c
src/module/news_item.h
src/module/news_menu.c
src/module/news_menu.h
src/module/news_parse.c
src/module/news_parse.h
src/module/news_popup.c
src/module/news_popup.h
src/module/news_theme.c
src/module/news_theme.h
src/module/news_utils.c
src/module/news_utils.h
src/module/news_viewer.c
src/module/news_viewer.h

22
src/module/e_mod_main.c

@ -1,10 +1,10 @@
#include "News.h"
#define E_MOD_INIT_FAIL(m, msg) \
{ \
news_util_message_error_show(msg); \
e_modapi_shutdown(m); \
return NULL; \
#define E_MOD_INIT_FAIL(m, msg) \
{ \
news_util_message_error_show(msg); \
e_modapi_shutdown(m); \
return NULL; \
}
/* module requirements */
@ -49,11 +49,11 @@ e_modapi_init(E_Module *m)
DMAIN(("Initialisation ..."));
if (!news_config_init()) E_MOD_INIT_FAIL(m, _("Config init failed"));
if (!news_parse_init()) E_MOD_INIT_FAIL(m, _("Parser init failed"));
if (!news_feed_init()) E_MOD_INIT_FAIL(m, _("Feeds init failed"));
if (!news_viewer_init()) E_MOD_INIT_FAIL(m, _("Viewer init failed"));
if (!news_popup_init()) E_MOD_INIT_FAIL(m, _("Popup subsystem init failed"));
if (!news_config_init()) E_MOD_INIT_FAIL(m, D_("Config init failed"));
if (!news_parse_init()) E_MOD_INIT_FAIL(m, D_("Parser init failed"));
if (!news_feed_init()) E_MOD_INIT_FAIL(m, D_("Feeds init failed"));
if (!news_viewer_init()) E_MOD_INIT_FAIL(m, D_("Viewer init failed"));
if (!news_popup_init()) E_MOD_INIT_FAIL(m, D_("Popup subsystem init failed"));
e_gadcon_provider_register((E_Gadcon_Client_Class *)&_gadcon_class);
@ -216,7 +216,7 @@ _gc_orient(E_Gadcon_Client *gcc)
static char *
_gc_label(void)
{
return _("News");
return D_("News");
}
static Evas_Object *

2
src/module/e_mod_main.h

@ -1,3 +1,5 @@
#define D_(str) dgettext(PACKAGE, str)
#ifdef E_MOD_NEWS_TYPEDEFS
typedef struct _News News;

24
src/module/news_config.c

@ -97,24 +97,24 @@ news_config_init(void)
{
if (news->config->version < NEWS_CONFIG_VERSION)
{
news_util_message_show(_("<hilight>News module : Configuration Upgraded</hilight><br><br>"
"Your configuration of news module<br>"
"has been upgraded<br>"
"Your settings were removed<br>"
"Sorry for the inconvenience<br><br>"
"(%d -> %d)"), news->config->version, NEWS_CONFIG_VERSION);
news_util_message_show(D_("<hilight>News module : Configuration Upgraded</hilight><br><br>"
"Your configuration of news module<br>"
"has been upgraded<br>"
"Your settings were removed<br>"
"Sorry for the inconvenience<br><br>"
"(%d -> %d)"), news->config->version, NEWS_CONFIG_VERSION);
news->config = NULL;
}
else
{
if (news->config->version > NEWS_CONFIG_VERSION)
{
news_util_message_show(_("<hilight>News module : Configuration Downgraded</hilight><br><br>"
"Your configuration of News module<br>"
"has been downgraded<br>"
"Your settings were removed<br>"
"Sorry for the inconvenience<br><br>"
"(%d ->%d)"), news->config->version, NEWS_CONFIG_VERSION);
news_util_message_show(D_("<hilight>News module : Configuration Downgraded</hilight><br><br>"
"Your configuration of News module<br>"
"has been downgraded<br>"
"Your settings were removed<br>"
"Sorry for the inconvenience<br><br>"
"(%d ->%d)"), news->config->version, NEWS_CONFIG_VERSION);
news->config = NULL;
}
}

68
src/module/news_config_dialog.c

@ -87,7 +87,7 @@ news_config_dialog_show(void)
v->advanced.create_widgets = _advanced_create_widgets;
cfd = e_config_dialog_new(e_container_current_get(e_manager_current_get()),
_("News Main Configuration"),
D_("News Main Configuration"),
"E", DIALOG_CLASS,
news_theme_file_get(NEWS_THEME_CAT_ICON), 0, v, NULL);
@ -187,22 +187,22 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
o = e_widget_list_add(evas, 0, 0);
of = e_widget_frametable_add(evas, _("Feeds"), 0);
of = e_widget_frametable_add(evas, D_("Feeds"), 0);
ob = e_widget_check_add(evas, _("Sort lists by name (disable Move action)"), &(cfdata->feed.sort_name));
ob = e_widget_check_add(evas, D_("Sort lists by name (disable Move action)"), &(cfdata->feed.sort_name));
e_widget_frametable_object_append(of, ob, 0, 1, 2, 1, 1, 1, 1, 0);
e_widget_list_object_append(o, of, 1, 1, 0.5);
of = e_widget_frametable_add(evas, _("News Viewer"), 0);
of = e_widget_frametable_add(evas, D_("News Viewer"), 0);
ob = e_widget_label_add(evas, _("Font size"));
ob = e_widget_label_add(evas, D_("Font size"));
e_widget_frametable_object_append(of, ob, 0, 0, 1, 1, 1, 1, 1, 1);
ob = e_widget_slider_add(evas, 1, 0, _("%1.0f"), NEWS_VIEWER_VCONTENT_FONT_SIZE_MIN, NEWS_VIEWER_VCONTENT_FONT_SIZE_MAX, 1.0, 0, NULL, &(cfdata->viewer.vcontent.font_size), 50);
ob = e_widget_slider_add(evas, 1, 0, D_("%1.0f"), NEWS_VIEWER_VCONTENT_FONT_SIZE_MIN, NEWS_VIEWER_VCONTENT_FONT_SIZE_MAX, 1.0, 0, NULL, &(cfdata->viewer.vcontent.font_size), 50);
e_widget_frametable_object_append(of, ob, 0, 1, 1, 1, 1, 0, 1, 0);
ob = e_widget_label_add(evas, _("Font color"));
ob = e_widget_label_add(evas, D_("Font color"));
e_widget_frametable_object_append(of, ob, 1, 0, 1, 1, 1, 1, 1, 1);
ob = e_widget_color_well_add(evas, cfdata->viewer.vcontent.font_color, 1);
@ -225,51 +225,51 @@ _advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data
o2 = e_widget_list_add(evas, 0, 0);
of = e_widget_frametable_add(evas, _("Feeds"), 0);
of = e_widget_frametable_add(evas, D_("Feeds"), 0);
ob = e_widget_label_add(evas, _("Timer"));
ob = e_widget_label_add(evas, D_("Timer"));
e_widget_frametable_object_append(of, ob, 0, 0, 1, 1, 1, 1, 1, 0);
ob = e_widget_slider_add(evas, 1, 0, _("%1.0f min"),
ob = e_widget_slider_add(evas, 1, 0, D_("%1.0f min"),
(float)NEWS_FEED_TIMER_MIN, (float)NEWS_FEED_TIMER_MAX,
1.0, 0, NULL, &(cfdata->feed.timer_m), 70);
e_widget_frametable_object_append(of, ob, 1, 0, 1, 1, 1, 1, 1, 0);
ob = e_widget_check_add(evas, _("Sort lists by name (disable Move action)"), &(cfdata->feed.sort_name));
ob = e_widget_check_add(evas, D_("Sort lists by name (disable Move action)"), &(cfdata->feed.sort_name));
e_widget_frametable_object_append(of, ob, 0, 1, 2, 1, 1, 1, 1, 0);
e_widget_list_object_append(o2, of, 1, 1, 0.5);
of = e_widget_framelist_add(evas, _("Browser"), 0);
of = e_widget_framelist_add(evas, D_("Browser"), 0);
ob = e_widget_label_add(evas, _("Uses xdg-open script, from freedesktop.org"));
ob = e_widget_label_add(evas, D_("Uses xdg-open script, from freedesktop.org"));
e_widget_framelist_object_append(of, ob);
e_widget_list_object_append(o2, of, 1, 1, 0.5);
of = e_widget_frametable_add(evas, _("Popup On News"), 0);
of = e_widget_frametable_add(evas, D_("Popup On News"), 0);
rg = e_widget_radio_group_new(&(cfdata->popup_news.active));
ob = e_widget_radio_add(evas, _("Never"),
ob = e_widget_radio_add(evas, D_("Never"),
NEWS_FEED_POPUP_NEWS_ACTIVE_NO, rg);
//TODO: NOT IMPLEMENTED YET
e_widget_radio_toggle_set(ob, 0);
e_widget_disabled_set(ob, 1);
e_widget_frametable_object_append(of, ob, 0, 0, 1, 1, 1, 1, 1, 0);
ob = e_widget_radio_add(evas, _("Only on urgent feeds"),
ob = e_widget_radio_add(evas, D_("Only on urgent feeds"),
NEWS_FEED_POPUP_NEWS_ACTIVE_URGENT, rg);
//TODO: NOT IMPLEMENTED YET
e_widget_radio_toggle_set(ob, 0);
e_widget_disabled_set(ob, 1);
e_widget_frametable_object_append(of, ob, 1, 0, 1, 1, 1, 1, 1, 0);
ob = e_widget_radio_add(evas, _("On all feeds"),
ob = e_widget_radio_add(evas, D_("On all feeds"),
NEWS_FEED_POPUP_NEWS_ACTIVE_ALL, rg);
//TODO: NOT IMPLEMENTED YET
e_widget_radio_toggle_set(ob, 0);
e_widget_disabled_set(ob, 1);
e_widget_frametable_object_append(of, ob, 1, 1, 1, 1, 1, 1, 1, 0);
ob = e_widget_label_add(evas, _("Timer"));
ob = e_widget_label_add(evas, D_("Timer"));
e_widget_frametable_object_append(of, ob, 0, 2, 1, 1, 1, 1, 1, 0);
ob = e_widget_slider_add(evas, 1, 0, _("%1.0f s"),
ob = e_widget_slider_add(evas, 1, 0, D_("%1.0f s"),
(float)NEWS_POPUP_TIMER_S_MIN,
(float)NEWS_POPUP_TIMER_S_MAX,
1.0, 0, NULL, &(cfdata->popup_news.timer_s), 70);
@ -277,19 +277,19 @@ _advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data
e_widget_list_object_append(o2, of, 1, 1, 0.5);
of = e_widget_frametable_add(evas, _("Popup On Warning / Error"), 0);
of = e_widget_frametable_add(evas, D_("Popup On Warning / Error"), 0);
//TODO: NOT IMPLEMENTED YET
news->config->popup_other.on_timeout = 0;
cfdata->popup_other.on_timeout = 0;
ob = e_widget_check_add(evas, _("Show on timeout ?"), &(cfdata->popup_other.on_timeout));
ob = e_widget_check_add(evas, D_("Show on timeout ?"), &(cfdata->popup_other.on_timeout));
//TODO: NOT IMPLEMENTED YET
e_widget_disabled_set(ob, 1);
e_widget_frametable_object_append(of, ob, 0, 0, 2, 1, 1, 0, 1, 0);
ob = e_widget_label_add(evas, _("Timer"));
ob = e_widget_label_add(evas, D_("Timer"));
e_widget_frametable_object_append(of, ob, 0, 1, 1, 1, 1, 1, 1, 0);
ob = e_widget_slider_add(evas, 1, 0, _("%1.0f s"),
ob = e_widget_slider_add(evas, 1, 0, D_("%1.0f s"),
(float)NEWS_POPUP_TIMER_S_MIN,
(float)NEWS_POPUP_TIMER_S_MAX,
1.0, 0, NULL, &(cfdata->popup_other.timer_s), 70);
@ -302,18 +302,18 @@ _advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data
o2 = e_widget_list_add(evas, 0, 0);
of = e_widget_frametable_add(evas, _("News Viewer"), 0);
of = e_widget_frametable_add(evas, D_("News Viewer"), 0);
ob = e_widget_check_add(evas, _("Unread feeds first"), &(cfdata->viewer.vfeeds.unread_first));
ob = e_widget_check_add(evas, D_("Unread feeds first"), &(cfdata->viewer.vfeeds.unread_first));
e_widget_frametable_object_append(of, ob, 0, 0, 1, 1, 1, 0, 1, 0);
ob = e_widget_check_add(evas, _("Unread articles first"), &(cfdata->viewer.varticles.unread_first));
ob = e_widget_check_add(evas, D_("Unread articles first"), &(cfdata->viewer.varticles.unread_first));
e_widget_frametable_object_append(of, ob, 1, 0, 1, 1, 1, 0, 1, 0);
ob = e_widget_check_add(evas, _("Sort articles by date"), &(cfdata->viewer.varticles.sort_date));
ob = e_widget_check_add(evas, D_("Sort articles by date"), &(cfdata->viewer.varticles.sort_date));
e_widget_frametable_object_append(of, ob, 1, 1, 1, 1, 1, 0, 1, 0);
of2 = e_widget_frametable_add(evas, _("Font"), 0);
of2 = e_widget_frametable_add(evas, D_("Font"), 0);
ob = e_widget_slider_add(evas, 1, 0, _("%1.0f"), NEWS_VIEWER_VCONTENT_FONT_SIZE_MIN, NEWS_VIEWER_VCONTENT_FONT_SIZE_MAX, 1.0, 0, NULL, &(cfdata->viewer.vcontent.font_size), 70);
ob = e_widget_slider_add(evas, 1, 0, D_("%1.0f"), NEWS_VIEWER_VCONTENT_FONT_SIZE_MIN, NEWS_VIEWER_VCONTENT_FONT_SIZE_MAX, 1.0, 0, NULL, &(cfdata->viewer.vcontent.font_size), 70);
e_widget_frametable_object_append(of2, ob, 0, 0, 1, 1, 1, 0, 1, 0);
ob = e_widget_color_well_add(evas, cfdata->viewer.vcontent.font_color, 1);
@ -321,7 +321,7 @@ _advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data
e_widget_on_change_hook_set(ob, _cb_color_viewer_font_change, cfdata);
e_widget_frametable_object_append(of2, ob, 0, 1, 1, 1, 1, 0, 1, 0);
ob = e_widget_check_add(evas, _("Font Shadow"), &cfdata->viewer.vcontent.font_shadow);
ob = e_widget_check_add(evas, D_("Font Shadow"), &cfdata->viewer.vcontent.font_shadow);
e_widget_frametable_object_append(of2, ob, 1, 0, 1, 1, 1, 0, 1, 0);
ob = e_widget_color_well_add(evas, cfdata->viewer.vcontent.font_shadow_color, 1);
@ -333,15 +333,15 @@ _advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data
e_widget_list_object_append(o2, of, 1, 1, 0.0);
of = e_widget_frametable_add(evas, _("Proxy"), 0);
of = e_widget_frametable_add(evas, D_("Proxy"), 0);
ob = e_widget_check_add(evas, _("Enable"), &(cfdata->proxy.enable));
ob = e_widget_check_add(evas, D_("Enable"), &(cfdata->proxy.enable));
e_widget_frametable_object_append(of, ob, 0, 0, 2, 1, 1, 0, 0, 0);
ob = e_widget_label_add(evas, _("Host"));
ob = e_widget_label_add(evas, D_("Host"));
e_widget_frametable_object_append(of, ob, 0, 1, 1, 1, 1, 0, 0, 0);
ob = e_widget_entry_add(evas, &(cfdata->proxy.host), NULL, NULL, NULL);
e_widget_frametable_object_append(of, ob, 1, 1, 1, 1, 1, 0, 1, 0);
ob = e_widget_label_add(evas, _("Port"));
ob = e_widget_label_add(evas, D_("Port"));
e_widget_frametable_object_append(of, ob, 0, 2, 1, 1, 1, 0, 0, 0);
ob = e_widget_entry_add(evas, &(cfdata->proxy.port), NULL, NULL, NULL);
e_widget_frametable_object_append(of, ob, 1, 2, 1, 1, 1, 0, 1, 0);

12
src/module/news_config_dialog_category.c

@ -47,7 +47,7 @@ news_config_dialog_category_show(News_Feed_Category *fcat)
v->basic.create_widgets = _basic_create_widgets;
cfd = e_config_dialog_new(e_container_current_get(e_manager_current_get()),
_("News Category Configuration"),
D_("News Category Configuration"),
"E", "_e_mod_news_config_dialog_category",
news_theme_file_get(NEWS_THEME_CAT_ICON), 0, v, fcat);
@ -132,7 +132,7 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
o = e_widget_list_add(evas, 0, 0);
of = e_widget_framelist_add(evas, _("Icon"), 0);
of = e_widget_framelist_add(evas, D_("Icon"), 0);
ob = e_widget_button_add(evas, "", NULL,
_icon_select, cfdata, NULL);
cfdata->gui.button_icon = ob;
@ -142,7 +142,7 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
e_widget_framelist_object_append(of, ob);
e_widget_list_object_append(o, of, 1, 1, 0.0);
of = e_widget_framelist_add(evas, _("Name"), 0);
of = e_widget_framelist_add(evas, D_("Name"), 0);
ob = e_widget_entry_add(evas, &(cfdata->name), NULL, NULL, NULL);
e_widget_framelist_object_append(of, ob);
e_widget_list_object_append(o, of, 1, 1, 0.0);
@ -200,7 +200,7 @@ _icon_select(void *data1, void *data2)
dia = e_dialog_new(cfd->con, "E", "_news_category_icon_select_dialog");
if (!dia) return;
e_dialog_title_set(dia, _("Select an Icon"));
e_dialog_title_set(dia, D_("Select an Icon"));
dia->data = cfdata;
if (cfdata->icon)
@ -225,8 +225,8 @@ _icon_select(void *data1, void *data2)
e_dialog_content_set(dia, o, mw, mh);
/* buttons at the bottom */
e_dialog_button_add(dia, _("OK"), NULL, _icon_select_ok, cfdata);
e_dialog_button_add(dia, _("Cancel"), NULL, _icon_select_cancel, cfdata);
e_dialog_button_add(dia, D_("OK"), NULL, _icon_select_ok, cfdata);
e_dialog_button_add(dia, D_("Cancel"), NULL, _icon_select_cancel, cfdata);
e_dialog_resizable_set(dia, 1);
e_win_centered_set(dia->win, 1);
e_dialog_show(dia);

42
src/module/news_config_dialog_feed.c

@ -60,7 +60,7 @@ news_config_dialog_feed_show(News_Feed *feed)
if (!evas_list_count(news->config->feed.categories))
{
news_util_message_error_show(_("You need to <hilight>create a category</hilight> first"));
news_util_message_error_show(D_("You need to <hilight>create a category</hilight> first"));
return 0;
}
@ -74,7 +74,7 @@ news_config_dialog_feed_show(News_Feed *feed)
v->advanced.create_widgets = _advanced_create_widgets;
cfd = e_config_dialog_new(e_container_current_get(e_manager_current_get()),
_("News Feed Configuration"),
D_("News Feed Configuration"),
"E", "_e_mod_news_config_dialog_feed",
news_theme_file_get(NEWS_THEME_CAT_ICON), 0, v, feed);
@ -326,7 +326,7 @@ _common_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *c
{
Evas_Object *of, *ob;
of = e_widget_frametable_add(evas, _("Basic informations"), 0);
of = e_widget_frametable_add(evas, D_("Basic informations"), 0);
ob = e_widget_button_add(evas, "", NULL,
_icon_select, cfdata, NULL);
@ -336,26 +336,26 @@ _common_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *c
e_widget_min_size_set(ob, 48, 48);
e_widget_frametable_object_append(of, ob, 0, 0, 1, 1, 0, 0, 0, 0);
//ob = e_widget_check_add(evas, _("Get from the server"), &(cfdata->icon_ovrw));
//ob = e_widget_check_add(evas, D_("Get from the server"), &(cfdata->icon_ovrw));
//TODO: NOT IMPLEMENTED YET
//e_widget_check_checked_set(ob, 0);
//e_widget_disabled_set(ob, 1);
// e_widget_list_object_append(o2, of, 1, 1, 0.5);
ob = e_widget_label_add(evas, _("Name :"));
ob = e_widget_label_add(evas, D_("Name :"));
e_widget_frametable_object_append(of, ob, 0, 1, 1, 1, 1, 0, 1, 0);
ob = e_widget_entry_add(evas, &(cfdata->name), NULL, NULL, NULL);
e_widget_frametable_object_append(of, ob, 0, 2, 1, 1, 1, 0, 1, 0);
ob = e_widget_label_add(evas, _("Feed url :"));
ob = e_widget_label_add(evas, D_("Feed url :"));
e_widget_frametable_object_append(of, ob, 0, 3, 1, 1, 1, 0, 1, 0);
ob = e_widget_entry_add(evas, &(cfdata->url_feed), NULL, NULL, NULL);
e_widget_frametable_object_append(of, ob, 0, 4, 1, 1, 1, 0, 1, 0);
ob = e_widget_check_add(evas, _("Mark as important feed"), &(cfdata->important));
ob = e_widget_check_add(evas, D_("Mark as important feed"), &(cfdata->important));
e_widget_frametable_object_append(of, ob, 0, 5, 1, 1, 1, 0, 1, 0);
e_widget_table_object_append(o, of, 0, 0, 2, 1, 1, 1, 1, 1);
of = e_widget_framelist_add(evas, _("Category"), 0);
of = e_widget_framelist_add(evas, D_("Category"), 0);
ob = e_widget_ilist_add(evas, 16, 16, NULL);
e_widget_ilist_selector_set(ob, 1);
@ -365,7 +365,7 @@ _common_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *c
e_widget_table_object_append(o, of, 2, 0, 2, 1, 1, 1, 1, 1);
of = e_widget_framelist_add(evas, _("Language"), 0);
of = e_widget_framelist_add(evas, D_("Language"), 0);
ob = e_widget_ilist_add(evas, 16, 16, NULL);
e_widget_ilist_selector_set(ob, 1);
@ -388,13 +388,13 @@ _advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data
_common_create_widgets(cfd, evas, cfdata, o);
of = e_widget_framelist_add(evas, _("Advanced informations"), 0);
of = e_widget_framelist_add(evas, D_("Advanced informations"), 0);
ob = e_widget_label_add(evas, _("Description"));
ob = e_widget_label_add(evas, D_("Description"));
e_widget_framelist_object_append(of, ob);
ob = e_widget_entry_add(evas, &(cfdata->description), NULL, NULL, NULL);
e_widget_framelist_object_append(of, ob);
ob = e_widget_label_add(evas, _("Home url"));
ob = e_widget_label_add(evas, D_("Home url"));
e_widget_framelist_object_append(of, ob);
ob = e_widget_entry_add(evas, &(cfdata->url_home), NULL, NULL, NULL);
e_widget_framelist_object_append(of, ob);
@ -402,18 +402,18 @@ _advanced_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data
e_widget_table_object_append(o, of, 0, 1, 3, 1, 1, 1, 1, 1);
of = e_widget_framelist_add(evas, _("Server informations"), 0);
of = e_widget_framelist_add(evas, D_("Server informations"), 0);
ob = e_widget_label_add(evas, _("Do allow the server to overwrite the informations you entered ?"));
ob = e_widget_label_add(evas, D_("Do allow the server to overwrite the informations you entered ?"));
e_widget_framelist_object_append(of, ob);
ob = e_widget_check_add(evas, _("Name"), &(cfdata->name_ovrw));
ob = e_widget_check_add(evas, D_("Name"), &(cfdata->name_ovrw));
e_widget_framelist_object_append(of, ob);
ob = e_widget_check_add(evas, _("Language"), &(cfdata->language_ovrw));
ob = e_widget_check_add(evas, D_("Language"), &(cfdata->language_ovrw));
e_widget_framelist_object_append(of, ob);
ob = e_widget_check_add(evas, _("Description"), &(cfdata->description_ovrw));
ob = e_widget_check_add(evas, D_("Description"), &(cfdata->description_ovrw));
e_widget_framelist_object_append(of, ob);
ob = e_widget_check_add(evas, _("Home url"), &(cfdata->url_home_ovrw));
ob = e_widget_check_add(evas, D_("Home url"), &(cfdata->url_home_ovrw));
e_widget_framelist_object_append(of, ob);
e_widget_table_object_append(o, of, 3, 1, 3, 1, 1, 1, 1, 1);
@ -536,7 +536,7 @@ _icon_select(void *data1, void *data2)
dia = e_dialog_new(cfd->con, "E", "_news_feed_icon_select_dialog");
if (!dia) return;
e_dialog_title_set(dia, _("Select an Icon"));
e_dialog_title_set(dia, D_("Select an Icon"));
dia->data = cfdata;
if (cfdata->icon)
@ -561,8 +561,8 @@ _icon_select(void *data1, void *data2)
e_dialog_content_set(dia, o, mw, mh);
/* buttons at the bottom */
e_dialog_button_add(dia, _("OK"), NULL, _icon_select_ok, cfdata);
e_dialog_button_add(dia, _("Cancel"), NULL, _icon_select_cancel, cfdata);
e_dialog_button_add(dia, D_("OK"), NULL, _icon_select_ok, cfdata);
e_dialog_button_add(dia, D_("Cancel"), NULL, _icon_select_cancel, cfdata);
e_dialog_resizable_set(dia, 1);
e_win_centered_set(dia->win, 1);
e_dialog_show(dia);

50
src/module/news_config_dialog_feeds.c

@ -79,7 +79,7 @@ news_config_dialog_feeds_show(void)
v->basic.create_widgets = _basic_create_widgets;
cfd = e_config_dialog_new(e_container_current_get(e_manager_current_get()),
_("News Feeds Configuration"),
D_("News Feeds Configuration"),
"E", DIALOG_CLASS,
news_theme_file_get(NEWS_THEME_CAT_ICON), 0, v, NULL);
@ -287,7 +287,7 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
o2 = e_widget_list_add(evas, 0, 0);
of = e_widget_frametable_add(evas, _("Categories"), 0);
of = e_widget_frametable_add(evas, D_("Categories"), 0);
cfdata->selected_category = NULL;
ob = e_widget_ilist_add(evas, 16, 16, NULL);
@ -311,12 +311,12 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
cfdata->button_cat_down = NULL;
}
ob = e_widget_button_add(evas, _("Add"), NULL, _cb_category_add, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Add"), NULL, _cb_category_add, cfdata, NULL);
e_widget_frametable_object_append(of, ob, 0, 2, 2, 1, 1, 0, 1, 0);
ob = e_widget_button_add(evas, _("Delete"), NULL, _cb_category_del, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Delete"), NULL, _cb_category_del, cfdata, NULL);
cfdata->button_cat_del = ob;
e_widget_frametable_object_append(of, ob, 2, 2, 2, 1, 1, 0, 1, 0);
ob = e_widget_button_add(evas, _("Configure"), NULL, _cb_category_config, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Configure"), NULL, _cb_category_config, cfdata, NULL);
cfdata->button_cat_conf = ob;
_buttons_category_update(cfdata);
e_widget_frametable_object_append(of, ob, 4, 2, 2, 1, 1, 0, 1, 0);
@ -328,12 +328,12 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
o3 = e_widget_list_add(evas, 0, 1);
of = e_widget_framelist_add(evas, _("Languages"), 1);
of = e_widget_framelist_add(evas, D_("Languages"), 1);
ob = e_widget_check_add(evas, _("All"), &(cfdata->langs_all));
ob = e_widget_check_add(evas, D_("All"), &(cfdata->langs_all));
e_widget_on_change_hook_set(ob, _cb_langs_all_change, cfdata);
e_widget_framelist_object_append(of, ob);
ob = e_widget_button_add(evas, _("Select"), NULL, _cb_langs_config, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Select"), NULL, _cb_langs_config, cfdata, NULL);
if (cfdata->langs_all)
e_widget_disabled_set(ob, 1);
cfdata->button_langs = ob;
@ -343,10 +343,10 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
o4 = e_widget_list_add(evas, 0, 0);
ob = e_widget_button_add(evas, _("Empty the lists"), "enlightenment/e", _cb_empty, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Empty the lists"), "enlightenment/e", _cb_empty, cfdata, NULL);
e_widget_list_object_append(o4, ob, 1, 0, 0.5);
ob = e_widget_button_add(evas, _("Restore default lists"), "enlightenment/e", _cb_reset, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Restore default lists"), "enlightenment/e", _cb_reset, cfdata, NULL);
e_widget_list_object_append(o4, ob, 1, 0, 0.5);
e_widget_list_object_append(o3, o4, 1, 1, 0.5);
@ -355,7 +355,7 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
e_widget_list_object_append(o, o2, 1, 1, 0.5);
of = e_widget_frametable_add(evas, _("Feeds"), 0);
of = e_widget_frametable_add(evas, D_("Feeds"), 0);
ob = e_widget_textblock_add(evas);
cfdata->textblock_feed_infos = ob;
@ -385,12 +385,12 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
cfdata->button_feed_down = NULL;
}
ob = e_widget_button_add(evas, _("Add"), NULL, _cb_feed_add, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Add"), NULL, _cb_feed_add, cfdata, NULL);
e_widget_frametable_object_append(of, ob, 0, 3, 2, 1, 1, 0, 1, 0);
ob = e_widget_button_add(evas, _("Delete"), NULL, _cb_feed_del, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Delete"), NULL, _cb_feed_del, cfdata, NULL);
cfdata->button_feed_del = ob;
e_widget_frametable_object_append(of, ob, 2, 3, 2, 1, 1, 0, 1, 0);
ob = e_widget_button_add(evas, _("Configure"), NULL, _cb_feed_config, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Configure"), NULL, _cb_feed_config, cfdata, NULL);
cfdata->button_feed_conf = ob;
_buttons_feed_update(cfdata);
e_widget_frametable_object_append(of, ob, 4, 3, 2, 1, 1, 0, 1, 0);
@ -683,8 +683,8 @@ _cb_category_del(void *data, void *data2)
if (!c) return;
if (c->feeds && evas_list_count(c->feeds))
{
news_util_message_error_show(_("There are <hilight>feeds</hilight> in this category.<br>"
"You have to <hilight>remove them first</hilight>"));
news_util_message_error_show(D_("There are <hilight>feeds</hilight> in this category.<br>"
"You have to <hilight>remove them first</hilight>"));
return;
}
@ -751,10 +751,10 @@ _cb_empty(void *data, void *data2)
cfdata = data;
if (cfdata->cd) return;
cd = e_confirm_dialog_show(_("News Module - Are you sure ?"), "enlightenment/e",
"<hilight>Empty the lists</hilight><br>"
"It will delete all the categories and feeds<br><br>"
"<hilight>Confirm ?</hilight>",
cd = e_confirm_dialog_show(D_("News Module - Are you sure ?"), "enlightenment/e",
"<hilight>Empty the lists</hilight><br>"
"It will delete all the categories and feeds<br><br>"
"<hilight>Confirm ?</hilight>",
NULL, NULL, _cb_empty_yes, NULL, NULL, NULL,
_cb_confirm_dialog_destroy, cfdata);
if (!cd) return;
@ -776,11 +776,11 @@ _cb_reset(void *data, void *data2)
cfdata = data;
if (cfdata->cd) return;
cd = e_confirm_dialog_show(_("News Module - Are you sure ?"), "enlightenment/e",
"<hilight>Restore default lists</hilight><br>"
"It will delete all the categories and feeds,<br>"
"and restore the default ones<br><br>"
"<hilight>Confirm ?</hilight>",
cd = e_confirm_dialog_show(D_("News Module - Are you sure ?"), "enlightenment/e",
"<hilight>Restore default lists</hilight><br>"
"It will delete all the categories and feeds,<br>"
"and restore the default ones<br><br>"
"<hilight>Confirm ?</hilight>",
NULL, NULL, _cb_reset_yes, NULL, NULL, NULL,
_cb_confirm_dialog_destroy, cfdata);
if (!cd) return;

26
src/module/news_config_dialog_item.c

@ -37,7 +37,7 @@ news_config_dialog_item_show(News_Item *ni)
v->basic.create_widgets = _basic_create_widgets;
cfd = e_config_dialog_new(e_container_current_get(e_manager_current_get()),
_("News Gadget Configuration"),
D_("News Gadget Configuration"),
"E", DIALOG_CLASS,
news_theme_file_get(NEWS_THEME_CAT_ICON), 0, v, ni);
@ -101,39 +101,39 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
o = e_widget_list_add(evas, 0, 0);
of = e_widget_framelist_add(evas, _("View Mode"), 0);
of = e_widget_framelist_add(evas, D_("View Mode"), 0);
rg = e_widget_radio_group_new(&(cfdata->view_mode));
ob = e_widget_radio_add(evas, _("Show one icon for all feeds"), NEWS_ITEM_VIEW_MODE_ONE, rg);
ob = e_widget_radio_add(evas, D_("Show one icon for all feeds"), NEWS_ITEM_VIEW_MODE_ONE, rg);
e_widget_framelist_object_append(of, ob);
ob = e_widget_radio_add(evas, _("Show all feeds"), NEWS_ITEM_VIEW_MODE_FEED, rg);
ob = e_widget_radio_add(evas, D_("Show all feeds"), NEWS_ITEM_VIEW_MODE_FEED, rg);
e_widget_framelist_object_append(of, ob);
ob = e_widget_radio_add(evas, _("Show unread feeds"), NEWS_ITEM_VIEW_MODE_FEED_UNREAD, rg);
ob = e_widget_radio_add(evas, D_("Show unread feeds"), NEWS_ITEM_VIEW_MODE_FEED_UNREAD, rg);
e_widget_framelist_object_append(of, ob);
ob = e_widget_radio_add(evas, _("Show all feeds marked as important"), NEWS_ITEM_VIEW_MODE_FEED_IMPORTANT, rg);
ob = e_widget_radio_add(evas, D_("Show all feeds marked as important"), NEWS_ITEM_VIEW_MODE_FEED_IMPORTANT, rg);
e_widget_framelist_object_append(of, ob);
ob = e_widget_radio_add(evas, _("Show unread feeds marked as important"), NEWS_ITEM_VIEW_MODE_FEED_IMPORTANT_UNREAD, rg);
ob = e_widget_radio_add(evas, D_("Show unread feeds marked as important"), NEWS_ITEM_VIEW_MODE_FEED_IMPORTANT_UNREAD, rg);
e_widget_framelist_object_append(of, ob);
e_widget_list_object_append(o, of, 1, 1, 0.0);
of = e_widget_framelist_add(evas, _("Feed open in"), 0);
of = e_widget_framelist_add(evas, D_("Feed open in"), 0);
rg = e_widget_radio_group_new(&(cfdata->openmethod));
ob = e_widget_radio_add(evas, _("the feed viewer"), NEWS_ITEM_OPENMETHOD_VIEWER, rg);
ob = e_widget_radio_add(evas, D_("the feed viewer"), NEWS_ITEM_OPENMETHOD_VIEWER, rg);
e_widget_framelist_object_append(of, ob);
ob = e_widget_radio_add(evas, _("my favorite browser"), NEWS_ITEM_OPENMETHOD_BROWSER, rg);
ob = e_widget_radio_add(evas, D_("my favorite browser"), NEWS_ITEM_OPENMETHOD_BROWSER, rg);
e_widget_framelist_object_append(of, ob);
ob = e_widget_check_add(evas, _("Browser opens home url"), &(cfdata->browser_open_home));
ob = e_widget_check_add(evas, D_("Browser opens home url"), &(cfdata->browser_open_home));
e_widget_framelist_object_append(of, ob);
ob = e_widget_label_add(evas, _("instead of feed url"));
ob = e_widget_label_add(evas, D_("instead of feed url"));
e_widget_framelist_object_append(of, ob);
e_widget_list_object_append(o, of, 1, 1, 0.0);
ob = e_widget_label_add(evas, "");
e_widget_list_object_append(o, ob, 1, 1, 0.0);
ob = e_widget_check_add(evas, _("Apply this to all News gadgets"), &(cfdata->apply_to_all));
ob = e_widget_check_add(evas, D_("Apply this to all News gadgets"), &(cfdata->apply_to_all));
e_widget_list_object_append(o, ob, 1, 1, 0.0);
return o;

10
src/module/news_config_dialog_item_content.c

@ -50,7 +50,7 @@ news_config_dialog_item_content_show(News_Item *ni)
v->basic.create_widgets = _basic_create_widgets;
cfd = e_config_dialog_new(e_container_current_get(e_manager_current_get()),
_("News Gadget Content Configuration"),
D_("News Gadget Content Configuration"),
"E", DIALOG_CLASS,
news_theme_file_get(NEWS_THEME_CAT_ICON), 0, v, ni);
@ -255,7 +255,7 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
o = e_widget_list_add(evas, 0, 1);
of = e_widget_frametable_add(evas, _("Avalaible Feeds"), 0);
of = e_widget_frametable_add(evas, D_("Avalaible Feeds"), 0);
ob = e_widget_ilist_add(evas, 16, 16, NULL);
e_widget_ilist_multi_select_set(ob, 1);
@ -264,14 +264,14 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
e_widget_on_change_hook_set(ob, _cb_feed_change, cfdata);
e_widget_frametable_object_append(of, ob, 0, 0, 1, 1, 1, 1, 1, 1);
ob = e_widget_button_add(evas, _("Add this Feed"), NULL, _cb_feed_add, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Add this Feed"), NULL, _cb_feed_add, cfdata, NULL);
e_widget_disabled_set(ob, 1);
cfdata->button_add = ob;
e_widget_frametable_object_append(of, ob, 0, 1, 1, 1, 1, 1, 1, 0);
e_widget_list_object_append(o, of, 1, 1, 0.0);
of = e_widget_frametable_add(evas, _("Selected Feeds"), 0);
of = e_widget_frametable_add(evas, D_("Selected Feeds"), 0);
ob = e_widget_ilist_add(evas, 16, 16, NULL);
e_widget_ilist_multi_select_set(ob, 1);
@ -289,7 +289,7 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
cfdata->button_down = ob;
e_widget_frametable_object_append(of, ob, 1, 2, 1, 1, 0, 0, 0, 0);
ob = e_widget_button_add(evas, _("Remove this Feed"), NULL, _cb_feed_remove, cfdata, NULL);
ob = e_widget_button_add(evas, D_("Remove this Feed"), NULL, _cb_feed_remove, cfdata, NULL);
cfdata->button_rem = ob;
e_widget_disabled_set(ob, 1);
e_widget_frametable_object_append(of, ob, 0, 5, 1, 4, 1, 1, 1, 0);

8
src/module/news_config_dialog_langs.c

@ -42,7 +42,7 @@ news_config_dialog_langs_show(void)
v->basic.create_widgets = _basic_create_widgets;
cfd = e_config_dialog_new(e_container_current_get(e_manager_current_get()),
_("News Feeds Language Configuration"),
D_("News Feeds Language Configuration"),
"E", DIALOG_CLASS,
news_theme_file_get(NEWS_THEME_CAT_ICON), 0, v, NULL);
return 1;
@ -120,9 +120,9 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
if (news->config->feed.langs_notset)
{
ob = e_widget_label_add(evas, _("Welcome to News Module !"));
ob = e_widget_label_add(evas, D_("Welcome to News Module !"));
e_widget_list_object_append(o, ob, 1, 1, 0.5);
ob = e_widget_label_add(evas, _("Please select the languages that you are able to read"));
ob = e_widget_label_add(evas, D_("Please select the languages that you are able to read"));
e_widget_list_object_append(o, ob, 1, 1, 0.0);
ob = e_widget_label_add(evas, "");
e_widget_list_object_append(o, ob, 1, 1, 0.0);
@ -130,7 +130,7 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
l = cfdata->choices;
line = 0;
of = e_widget_framelist_add(evas, _("Languages"), 1);
of = e_widget_framelist_add(evas, D_("Languages"), 1);
ol = e_widget_list_add(evas, 0, 0);
for (l=cfdata->choices; l; l=evas_list_next(l))
{

20
src/module/news_feed.c

@ -288,34 +288,34 @@ news_feed_edit(News_Feed *f, char *name, int name_ovrw, char *language, int lang
if ( !name || !name[0] )
{
news_util_message_error_show(_("The <hilight>name</hilight> you entered is not correct"));
news_util_message_error_show(D_("The <hilight>name</hilight> you entered is not correct"));
return 0;
}
if (!category)
{
news_util_message_error_show(_("The need to <hilight>select a category</hilight>."));
news_util_message_error_show(D_("The need to <hilight>select a category</hilight>."));
return 0;
}
f2 = _feed_find(category, name);
if ( f2 && (f != f2) )
{
news_util_message_error_show(_("A feed with the <hilight>name</hilight> %s <hilight>already exists</hilight><br>"
"in the %s category<br><br>"
"Its not possible to have feeds with the same name<br>"
"in one category."),
news_util_message_error_show(D_("A feed with the <hilight>name</hilight> %s <hilight>already exists</hilight><br>"
"in the %s category<br><br>"
"Its not possible to have feeds with the same name<br>"
"in one category."),
name, category->name);
return 0;
}
if (!language || !language[0])
{
news_util_message_error_show(_("You need to select a <hilight>language</hilight>."));
news_util_message_error_show(D_("You need to select a <hilight>language</hilight>."));
return 0;
}
if ( !url_feed || !url_feed[0] ||
!(host = _get_host_from_url(url_feed)) ||
!(file = _get_file_from_url(url_feed)) )
{
news_util_message_error_show(_("The <hilight>url</hilight> you specified is not correct"));
news_util_message_error_show(D_("The <hilight>url</hilight> you specified is not correct"));
if (host) free(host);
return 0;
}
@ -877,7 +877,7 @@ news_feed_category_edit(News_Feed_Category *cat, char *name, char *icon)
if (!name || !name[0])
{
news_util_message_error_show(_("You need to enter a <hilight>name</hilight> !"));
news_util_message_error_show(D_("You need to enter a <hilight>name</hilight> !"));
return 0;
}
@ -885,7 +885,7 @@ news_feed_category_edit(News_Feed_Category *cat, char *name, char *icon)
cat2 = _feed_category_find(name);
if (cat2 && (cat2 != cat))
{
news_util_message_error_show(_("The <hilight>name</hilight> you entered is <hilight>already used</hilight><br>"
news_util_message_error_show(D_("The <hilight>name</hilight> you entered is <hilight>already used</hilight><br>"
"by another category"));
return 0;
}

16
src/module/news_menu.c

@ -53,7 +53,7 @@ news_menu_feed_show(News_Feed *f)
e_menu_post_deactivate_callback_set(mn, _cb_feed_deactivate_post, f);
mi = e_menu_item_new(mn);
e_menu_item_label_set(mi, _("Configure this feed"));
e_menu_item_label_set(mi, D_("Configure this feed"));
if (f->icon && f->icon[0])
e_menu_item_icon_file_set(mi, f->icon);
e_menu_item_callback_set(mi, _cb_configure_feed, f);
@ -127,13 +127,13 @@ _menu_append(E_Menu *mn, News_Item *ni)
if (ni->unread_count)
{
mi = e_menu_item_new(mn);
e_menu_item_label_set(mi, _("Set all feeds as read"));
e_menu_item_label_set(mi, D_("Set all feeds as read"));
news_theme_menu_icon_set(mi, NEWS_THEME_ICON_SETASREAD);
e_menu_item_callback_set(mi, _cb_item_setasread, ni);
}
mi = e_menu_item_new(mn);
e_menu_item_label_set(mi, _("Update all feeds"));
e_menu_item_label_set(mi, D_("Update all feeds"));
news_theme_menu_icon_set(mi, NEWS_THEME_ICON_UPDATE);
e_menu_item_callback_set(mi, _cb_item_update, ni);
@ -144,23 +144,23 @@ _menu_append(E_Menu *mn, News_Item *ni)
mn_conf = e_menu_new();
mi = e_menu_item_new(mn_conf);
e_menu_item_label_set(mi, _("Configure gadget"));
e_menu_item_label_set(mi, D_("Configure gadget"));
e_util_menu_item_edje_icon_set(mi, "enlightenment/configuration");
e_menu_item_callback_set(mi, _cb_configure_item, ni);
mi = e_menu_item_new(mn_conf);
e_menu_item_label_set(mi, _("Configure gadget content"));
e_menu_item_label_set(mi, D_("Configure gadget content"));
news_theme_menu_icon_set(mi, "icon");
e_menu_item_callback_set(mi, _cb_configure_item_content, ni);
mi = e_menu_item_new(mn_conf);
e_menu_item_label_set(mi, _("Main Configuration"));
e_menu_item_label_set(mi, D_("Main Configuration"));
e_util_menu_item_edje_icon_set(mi, "enlightenment/configuration");
e_menu_item_callback_set(mi, _cb_configure_main, NULL);
mi = e_menu_item_new(mn_conf);
e_menu_item_label_set(mi, _("Feeds Configuration"));
e_menu_item_label_set(mi, D_("Feeds Configuration"));
news_theme_menu_icon_set(mi, "icon");
e_menu_item_callback_set(mi, _cb_configure_feeds, NULL);
mi = e_menu_item_new(mn);
e_menu_item_label_set(mi, _("Configuration"));
e_menu_item_label_set(mi, D_("Configuration"));
e_util_menu_item_edje_icon_set(mi, "enlightenment/configuration");
e_menu_item_submenu_set(mi, mn_conf);

6
src/module/news_utils.h

@ -10,21 +10,21 @@
char __tmpbuf[4096]; \
\
snprintf(__tmpbuf, sizeof(__tmpbuf), ##args); \
e_module_dialog_show(news->module, _("News Module DEBUG DEBUG DEBUG DEBUG"), __tmpbuf); \
e_module_dialog_show(news->module, D_("News Module DEBUG DEBUG DEBUG DEBUG"), __tmpbuf); \
}
#define news_util_message_show(args...) \
{ \
char __tmpbuf[4096]; \
\
snprintf(__tmpbuf, sizeof(__tmpbuf), ##args); \
e_module_dialog_show(news->module, _("News Module"), __tmpbuf); \
e_module_dialog_show(news->module, D_("News Module"), __tmpbuf); \
}
#define news_util_message_error_show(args...) \
{ \
char __tmpbuf[4096]; \
\
snprintf(__tmpbuf, sizeof(__tmpbuf), ##args); \
e_module_dialog_show(news->module, _("News Module Error"), __tmpbuf); \
e_module_dialog_show(news->module, D_("News Module Error"), __tmpbuf); \
}
int news_util_url_image_get(char *url, void (*func_cb) (News_Feed_Document *doc, int error));