This repository was archived by the owner on Feb 25, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,6 @@ static constexpr char kChannelName[] = "flutter/platform";
12
12
static constexpr char kBadArgumentsError [] = " Bad Arguments" ;
13
13
static constexpr char kUnknownClipboardFormatError [] =
14
14
" Unknown Clipboard Format" ;
15
- static constexpr char kClipboardRequestError [] = " Clipboard Request Failed" ;
16
15
static constexpr char kFailedError [] = " Failed" ;
17
16
static constexpr char kGetClipboardDataMethod [] = " Clipboard.getData" ;
18
17
static constexpr char kSetClipboardDataMethod [] = " Clipboard.setData" ;
@@ -47,11 +46,9 @@ static void clipboard_text_cb(GtkClipboard* clipboard,
47
46
if (text != nullptr ) {
48
47
g_autoptr (FlValue) result = fl_value_new_map ();
49
48
fl_value_set_string_take (result, kTextKey , fl_value_new_string (text));
50
- response = FL_METHOD_RESPONSE (fl_method_success_response_new (nullptr ));
49
+ response = FL_METHOD_RESPONSE (fl_method_success_response_new (result ));
51
50
} else {
52
- response = FL_METHOD_RESPONSE (fl_method_error_response_new (
53
- kClipboardRequestError , " Failed to retrieve clipboard text from GTK" ,
54
- nullptr ));
51
+ response = FL_METHOD_RESPONSE (fl_method_success_response_new (nullptr ));
55
52
}
56
53
57
54
send_response (method_call, response);
You can’t perform that action at this time.
0 commit comments