aboutsummaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'plugins')
-rw-r--r--plugins/http-files/src/contact_titlebar_entry.vala8
1 files changed, 3 insertions, 5 deletions
diff --git a/plugins/http-files/src/contact_titlebar_entry.vala b/plugins/http-files/src/contact_titlebar_entry.vala
index 064adca9..3fd8ee39 100644
--- a/plugins/http-files/src/contact_titlebar_entry.vala
+++ b/plugins/http-files/src/contact_titlebar_entry.vala
@@ -35,10 +35,9 @@ public class ConversationTitlebarWidget : Button, Plugins.ConversationTitlebarWi
}
public void on_clicked() {
- FileChooserDialog chooser = new FileChooserDialog (
- "Select file", null, FileChooserAction.OPEN,
- "Cancel", ResponseType.CANCEL,
- "Select", ResponseType.ACCEPT);
+ FileChooserNative chooser = new FileChooserNative (
+ "Select file", get_toplevel() as Window, FileChooserAction.OPEN,
+ "Select", "Cancel");
int? max_file_size = stream_interactor.get_module(Manager.IDENTITY).get_max_file_size(conversation.account);
if (max_file_size != null) {
FileFilter filter = new FileFilter();
@@ -53,7 +52,6 @@ public class ConversationTitlebarWidget : Button, Plugins.ConversationTitlebarWi
string uri = chooser.get_filename();
stream_interactor.get_module(Manager.IDENTITY).send(conversation, uri);
}
- chooser.close();
}
public void on_upload_available(Account account) {