diff options
author | Claudio Saavedra <csaavedra@igalia.com> | 2011-07-06 01:17:07 +0800 |
---|---|---|
committer | Xan Lopez <xan@igalia.com> | 2012-03-07 04:49:43 +0800 |
commit | 0912ceb9c9762fbca6b1f0556a96c5cbace6658a (patch) | |
tree | 76b7d92a05e905d4650509bbe736470d4b04a7d8 /lib | |
parent | ee3f8488431daadcb7c1b445e68627ef0f5d7238 (diff) | |
download | gsoc2013-epiphany-0912ceb9c9762fbca6b1f0556a96c5cbace6658a.tar gsoc2013-epiphany-0912ceb9c9762fbca6b1f0556a96c5cbace6658a.tar.gz gsoc2013-epiphany-0912ceb9c9762fbca6b1f0556a96c5cbace6658a.tar.bz2 gsoc2013-epiphany-0912ceb9c9762fbca6b1f0556a96c5cbace6658a.tar.lz gsoc2013-epiphany-0912ceb9c9762fbca6b1f0556a96c5cbace6658a.tar.xz gsoc2013-epiphany-0912ceb9c9762fbca6b1f0556a96c5cbace6658a.tar.zst gsoc2013-epiphany-0912ceb9c9762fbca6b1f0556a96c5cbace6658a.zip |
ephy-profile-migrator: update to migrate also zoom level preferences
Diffstat (limited to 'lib')
-rw-r--r-- | lib/ephy-profile-migrator.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/ephy-profile-migrator.c b/lib/ephy-profile-migrator.c index aefc0dfc6..f660d9366 100644 --- a/lib/ephy-profile-migrator.c +++ b/lib/ephy-profile-migrator.c @@ -408,6 +408,7 @@ typedef struct { long long int visit_count; long long int last_visit; long long int first_visit; + double zoom_level; GList *visits; } HistoryParseData; @@ -432,6 +433,7 @@ history_parse_start_element (GMarkupParseContext *context, parse_data->visit_count = 0; parse_data->last_visit = 0; parse_data->first_visit = 0; + parse_data->zoom_level = 1.0; } else if (g_str_equal (element_name, "property")) { const char **name, **value; @@ -477,6 +479,10 @@ history_parse_text (GMarkupParseContext *context, GString *data = g_string_new_len (text, text_len); sscanf(data->str, "%lld", &parse_data->first_visit); g_string_free (data, TRUE); + } else if (g_str_equal (parse_data->current, "10")) { + GString *data = g_string_new_len (text, text_len); + sscanf(data->str, "%lf", &parse_data->zoom_level); + g_string_free (data, TRUE); } g_free (parse_data->current); @@ -502,6 +508,7 @@ history_parse_end_element (GMarkupParseContext *context, EphyHistoryPageVisit *visit = ephy_history_page_visit_new (parse_data->location ? parse_data->location : "", parse_data->last_visit, EPHY_PAGE_VISIT_TYPED); g_free (visit->url->title); visit->url->title = g_strdup (parse_data->title); + visit->url->zoom_level = parse_data->zoom_level; parse_data->visits = g_list_append (parse_data->visits, visit); } } |