|
72 | 72 | %rename (asktext) py_asktext; |
73 | 73 | %rename (str2ea) py_str2ea; |
74 | 74 | %rename (str2user) py_str2user; |
| 75 | + |
75 | 76 | %ignore process_ui_action; |
76 | 77 | %rename (process_ui_action) py_process_ui_action; |
77 | | -%ignore execute_sync; |
| 78 | + |
78 | 79 | %ignore exec_request_t; |
| 80 | + |
| 81 | +%ignore execute_sync; |
79 | 82 | %rename (execute_sync) py_execute_sync; |
80 | 83 |
|
| 84 | +%ignore read_selection; |
| 85 | +%rename (read_selection) py_read_selection; |
| 86 | + |
81 | 87 | %ignore ui_request_t; |
82 | 88 | %ignore execute_ui_requests; |
83 | 89 | %rename (execute_ui_requests) py_execute_ui_requests; |
@@ -139,6 +145,30 @@ SWIG_DECLARE_PY_CLINKED_OBJECT(textctrl_info_t) |
139 | 145 | //<inline(py_kernwin)> |
140 | 146 | //------------------------------------------------------------------------ |
141 | 147 |
|
| 148 | +//------------------------------------------------------------------------ |
| 149 | +/* |
| 150 | +#<pydoc> |
| 151 | +def read_selection(): |
| 152 | + """ |
| 153 | + Returns selected area boundaries |
| 154 | +
|
| 155 | + @return: tuple(ok: bool, start_ea, end_ea) |
| 156 | + """ |
| 157 | + pass |
| 158 | +#</pydoc> |
| 159 | +*/ |
| 160 | +static PyObject *py_read_selection() |
| 161 | +{ |
| 162 | + ea_t ea1, ea2; |
| 163 | + bool b = read_selection(&ea1, &ea2); |
| 164 | + |
| 165 | + PYW_GIL_CHECK_LOCKED_SCOPE(); |
| 166 | + return Py_BuildValue( |
| 167 | + "(i" PY_FMT64 PY_FMT64 ")", |
| 168 | + b ? 1 : 0, |
| 169 | + pyul_t(ea1), pyul_t(ea2)); |
| 170 | +} |
| 171 | + |
142 | 172 | //------------------------------------------------------------------------ |
143 | 173 | /* |
144 | 174 | #<pydoc> |
@@ -1398,11 +1428,6 @@ static bool formchgcbfa_set_field_value( |
1398 | 1428 |
|
1399 | 1429 | static size_t py_get_AskUsingForm() |
1400 | 1430 | { |
1401 | | - // Return a pointer to the function. Note that, although |
1402 | | - // the C implementation of AskUsingForm_cv will do some |
1403 | | - // Qt/txt widgets generation, the Python's ctypes |
1404 | | - // implementation through which the call well go will first |
1405 | | - // unblock other threads. No need to do it ourselves. |
1406 | 1431 | return (size_t)AskUsingForm_c; |
1407 | 1432 | } |
1408 | 1433 |
|
|
0 commit comments