app: don't drop the last reference to "file" in gimp_data_set_file(), argh

also improve precondition check in gimp_data_save().
app: port gimp_data_create_filename() to GFile

implies also porting gimp_data_factory_get_save_dir().