Removed moo_editor_set/get_default_lang

master
Yevgen Muntyan 2006-04-30 21:24:35 -05:00
parent 3169a40d29
commit 1f67912dcf
4 changed files with 17 additions and 38 deletions

View File

@ -1,5 +1,10 @@
AUTOMAKE_OPTIONS = dist-bzip2 foreign nostdinc
EXTRA_DIST = autogen.sh mingw-configure cygwin-configure
EXTRA_DIST = \
autogen.sh \
mingw-configure \
cygwin-configure \
makewin
DIST_SUBDIRS = m4

View File

@ -1825,24 +1825,6 @@ moo_editor_set_edit_type (MooEditor *editor,
}
void
moo_editor_set_default_lang (MooEditor *editor,
const char *name)
{
g_return_if_fail (MOO_IS_EDITOR (editor));
g_free (editor->priv->default_lang);
editor->priv->default_lang = g_strdup (name);
}
const char*
moo_editor_get_default_lang (MooEditor *editor)
{
g_return_val_if_fail (MOO_IS_EDITOR (editor), NULL);
return editor->priv->default_lang;
}
static void
prefs_changed (G_GNUC_UNUSED const char *key,
G_GNUC_UNUSED const GValue *newval,
@ -1854,6 +1836,16 @@ prefs_changed (G_GNUC_UNUSED const char *key,
}
static void
set_default_lang (MooEditor *editor,
const char *name)
{
g_return_if_fail (MOO_IS_EDITOR (editor));
g_free (editor->priv->default_lang);
editor->priv->default_lang = g_strdup (name);
}
static gboolean
apply_prefs (MooEditor *editor)
{
@ -1869,7 +1861,7 @@ apply_prefs (MooEditor *editor)
if (default_lang && !strcmp (default_lang, MOO_LANG_NONE))
default_lang = NULL;
moo_editor_set_default_lang (editor, default_lang);
set_default_lang (editor, default_lang);
use_tabs = !moo_prefs_get_bool (moo_edit_setting (MOO_EDIT_PREFS_SPACES_NO_TABS));
indent_width = moo_prefs_get_int (moo_edit_setting (MOO_EDIT_PREFS_INDENT_WIDTH));

View File

@ -118,9 +118,6 @@ MooEditor *moo_edit_window_get_editor (MooEditWindow *window);
MooEditor *moo_edit_get_editor (MooEdit *doc);
MooLangMgr *moo_editor_get_lang_mgr (MooEditor *editor);
void moo_editor_set_default_lang(MooEditor *editor,
const char *name);
const char *moo_editor_get_default_lang(MooEditor *editor);
void moo_editor_set_window_type (MooEditor *editor,
GType type);

View File

@ -202,21 +202,6 @@
(return-type "MooLangMgr*")
)
(define-method set_default_lang
(of-object "MooEditor")
(c-name "moo_editor_set_default_lang")
(return-type "none")
(parameters
'("const-char*" "name" (null-ok))
)
)
(define-method get_default_lang
(of-object "MooEditor")
(c-name "moo_editor_get_default_lang")
(return-type "const-char*")
)
(define-method set_window_type
(of-object "MooEditor")
(c-name "moo_editor_set_window_type")