mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
A file that we import should never become the default file we save to
Only files that are opened should be considered r/w. Files that are imported should be treated as if they were r/o. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
ffd3b8591d
commit
a2afe41280
5 changed files with 18 additions and 14 deletions
|
@ -336,7 +336,7 @@ static void file_open(GtkWidget *w, gpointer data)
|
|||
|
||||
GError *error = NULL;
|
||||
filename = fn_glist->data;
|
||||
parse_file(filename, &error);
|
||||
parse_file(filename, &error, TRUE);
|
||||
if (error != NULL)
|
||||
{
|
||||
report_error(error);
|
||||
|
@ -1371,7 +1371,7 @@ static GtkEntry *dive_computer_device(GtkWidget *vbox)
|
|||
static void do_import_file(gpointer data, gpointer user_data)
|
||||
{
|
||||
GError *error = NULL;
|
||||
parse_file(data, &error);
|
||||
parse_file(data, &error, FALSE);
|
||||
|
||||
if (error != NULL)
|
||||
{
|
||||
|
@ -1440,7 +1440,7 @@ static GError *setup_uemis_import(device_data_t *data)
|
|||
#ifdef DEBUGFILE
|
||||
fprintf(debugfile, "xml buffer \"%s\"\n\n", buf);
|
||||
#endif
|
||||
parse_xml_buffer("Uemis Download", buf, strlen(buf), &error);
|
||||
parse_xml_buffer("Uemis Download", buf, strlen(buf), &error, FALSE);
|
||||
set_uemis_last_dive(uemis_max_dive_data);
|
||||
#if UEMIS_DEBUG
|
||||
fprintf(debugfile, "uemis_max_dive_data: %s\n", uemis_max_dive_data);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue