[longomatch] Prompt user before remuxing file and handle cancellations
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [longomatch] Prompt user before remuxing file and handle cancellations
- Date: Fri, 2 Jan 2015 15:49:24 +0000 (UTC)
commit 38cdf0cddd7a897d4f234df0ef980c88b487247e
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date: Fri Jan 2 16:48:18 2015 +0100
Prompt user before remuxing file and handle cancellations
LongoMatch.GUI.Helpers/Misc.cs | 16 +++++++++++-----
1 files changed, 11 insertions(+), 5 deletions(-)
---
diff --git a/LongoMatch.GUI.Helpers/Misc.cs b/LongoMatch.GUI.Helpers/Misc.cs
index a5daa99..0cccb6d 100644
--- a/LongoMatch.GUI.Helpers/Misc.cs
+++ b/LongoMatch.GUI.Helpers/Misc.cs
@@ -355,15 +355,21 @@ namespace LongoMatch.Gui.Helpers
} else {
string q = Catalog.GetString ("This file needs to be
converted into a more suitable format." +
"(This step will only
take a few minutes)");
- gui.InfoMessage (q, parent);
- string newFilename = multimedia.RemuxFile (mediaFile,
parent);
- if (newFilename != null)
- mediaFile = multimedia.DiscoverFile
(newFilename);
+ if (gui.QuestionMessage (q, null, parent)) {
+ string newFilename = multimedia.RemuxFile
(mediaFile, parent);
+ if (newFilename != null) {
+ mediaFile = multimedia.DiscoverFile
(newFilename);
+ } else {
+ mediaFile = null;
+ }
+ } else {
+ mediaFile = null;
+ }
}
}
} catch (Exception ex) {
gui.ErrorMessage (ex.Message, parent);
- return null;
+ mediaFile = null;
}
}
return mediaFile;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]