X-Git-Url: http://vcs.maemo.org/git/?a=blobdiff_plain;f=src%2Fhildon2%2Fmodest-platform.c;h=e47bf1ffcab8aa26a23e0d7a0f014b823394d3d6;hb=57fb485a6a6b019a9eb4ea4f8bc465dd4fdbfc47;hp=7a451b5f67da89cf48b8a0e3f34489e520dbde67;hpb=916ebd254143284b9f09beadf5bac62a285fd604;p=modest diff --git a/src/hildon2/modest-platform.c b/src/hildon2/modest-platform.c index 7a451b5..e47bf1f 100644 --- a/src/hildon2/modest-platform.c +++ b/src/hildon2/modest-platform.c @@ -2949,7 +2949,14 @@ on_move_to_dialog_action_clicked (GtkButton *selection, selected = modest_folder_view_get_selected (MODEST_FOLDER_VIEW (folder_view)); if (selected) { - gtk_dialog_response (GTK_DIALOG (dialog), GTK_RESPONSE_OK); + /* It's not possible to select root folders as + targets unless they're the local account or + the memory card account */ + if ((TNY_IS_FOLDER (selected) && !TNY_IS_MERGE_FOLDER (selected)) || + (TNY_IS_ACCOUNT (selected) && + (modest_tny_account_is_virtual_local_folders (TNY_ACCOUNT (selected)) || + modest_tny_account_is_memory_card_account (TNY_ACCOUNT (selected))))) + gtk_dialog_response (GTK_DIALOG (dialog), GTK_RESPONSE_OK); g_object_unref (selected); } }