Commit Graph

4127 Commits

Author SHA1 Message Date
Paul Cornett
b5d4c6068e Make some member functions const 2021-03-17 09:44:48 -07:00
Tobias Taschner
97e469c255
Add access to user agent for wxWebView
Allow setting a custom user agent for a webview.
Also allow access to the current user agent.
2021-03-16 22:53:00 +01:00
Vadim Zeitlin
77593c5996 Add return value to wxSafeShowMessage()
This allows the caller to log the message to the console in addition to
showing the message box, for example. Previously, this would be
impossible to do without getting the duplicates if the message box was
not shown, but now it is.
2021-03-14 13:18:36 +01:00
Vadim Zeitlin
16495e424d Merge branch 'utf8-std-string'
Add wxString::utf8_string().

See https://github.com/wxWidgets/wxWidgets/pull/2265
2021-03-14 13:10:13 +01:00
Vadim Zeitlin
f6194cb797 Merge branch 'config-size_t'
Add support for 64-bit numbers and size_t to wxConfig.

See https://github.com/wxWidgets/wxWidgets/pull/2272
2021-03-13 22:35:01 +01:00
Vadim Zeitlin
0c837e5310 Add support for size_t to wxConfig
Allow writing and reading size_t values directly too, there were not
previously accepted unlike all the other arithmetic types.

Closes #19091.
2021-03-13 15:15:37 +01:00
Vadim Zeitlin
fce8780297 Add 64-bit integers support to wxConfig
Serialize them to strings in wxFileConfig, just as we always did for
long, but use wxRegKey support for storing them directly to the registry
in wxRegConfig.
2021-03-13 15:14:58 +01:00
Vadim Zeitlin
12d191823a Merge branch 'stc-typo-fixes'
Fix minor typos in STC docs.

See https://github.com/wxWidgets/wxWidgets/pull/2276
2021-03-13 13:35:28 +01:00
Vadim Zeitlin
5a623d3a4e Regenerate STC files after the typo fixes
Rerun src/stc/gen_iface.py.
2021-03-13 13:35:14 +01:00
Vadim Zeitlin
c88f23db3e Merge branch 'doc_misc' of https://github.com/TcT2k/wxWidgets
Various wxWebView docs improvements.

See https://github.com/wxWidgets/wxWidgets/pull/2266
2021-03-13 13:27:00 +01:00
Blake Madden
28d705424b Fix double words and article mismatches in docs. 2021-03-10 14:28:20 -05:00
Tobias Taschner
ecce094522
Document previously missing macOS wxWebView features 2021-03-09 22:13:15 +01:00
Tobias Taschner
b493970336
Apply suggestions from code review
Co-authored-by: VZ <vz-github@zeitlins.org>
2021-03-09 22:09:16 +01:00
Tobias Taschner
4e2b746ec2
Update wxWebView documentation
- Use subsections
- Unify layout of backend sections
- Refer to backends by consistent naming
- Remove Trident reference (while technically correct it's probably not very helpful for most)
- Add a warning to IE backend
- Add wxWebViewEdge doc
- Add missing event from wxWebViewEvent docs
2021-03-09 22:09:16 +01:00
Tobias Taschner
1e42ea4e97
Update some outdated notes from wxWebView docs 2021-03-09 22:09:15 +01:00
Vadim Zeitlin
3f2c84d4a9 Add 64-bit numbers support to wxRegKey
This uses the native registry support for 64-bit values available since
Windows XP.

Note that SetValue64() can't be just called SetValue() as this would
introduce ambiguities when writing an int or an enum to the registry.
This could be avoided by providing overloads for all the arithmetic
types, but it's arguably better to be more clear about what exactly is
being written to the registry in this low-level class and using a
different name is definitely simpler.
2021-03-09 21:09:42 +01:00
Vadim Zeitlin
e00d5e131b Use new wxAppTraits::SafeMessageBox() in wxSafeShowMessage()
This allows to show message boxes in ports other than wxMSW too by doing
it only when it is safe, i.e. when the GUI is initialized, while still
keeping the old code directly using the native MessageBox() function for
MSW for maximal robustness.
2021-03-07 23:51:54 +01:00
Vadim Zeitlin
69e48f036b Add wxApp::GetMainTopWindow() wrapper
This trivial function just allows to avoid checking if wxTheApp is not
null before calling GetTopWindow() on it.

Replace the existing "wxTheApp && wxTheApp->GetTopWindow()" calls with
wxApp::GetMainTopWindow().

No real changes.
2021-03-07 23:51:54 +01:00
Vadim Zeitlin
0f8e976ac3 Add wxString::utf8_string()
This adds a yet another conversion function, which is not ideal, but
still better than having to write ToStdString(wxConvUTF8) every time for
losslessly converting wxString to std::string: not only this is too
long, but it's also too easy to forget to specify wxConvUTF8, resulting
in data loss when using non-UTF-8 locale.
2021-03-06 15:12:07 +01:00
Vadim Zeitlin
bf8be6c58d Merge branch 'mac-filedlg-improvements' of https://github.com/discnl/wxWidgets
macOS wxFileDialog improvements.

See https://github.com/wxWidgets/wxWidgets/pull/2234
2021-03-06 12:18:43 +01:00
Vadim Zeitlin
3c92573dd7 Recommend using wxStaticBox as parent more strongly
Not doing it, i.e. creating the window inside the static box as its
siblings, rather than children, may appear to work, but actually doesn't
always do it, for example the windows are not shown correctly when using
RTL locale.

Closes #19086.
2021-03-05 22:53:27 +01:00
Andriy Byelikov
b2d97d1393 Add support for English locale for Israel (en_IL)
This locale is recognized by glibc, so add it to the known locales
database.

Closes https://github.com/wxWidgets/wxWidgets/pull/2252

See #19082.
2021-03-05 18:51:10 +01:00
Vadim Zeitlin
7bcac7bfde Merge branch 'unix-default-locale'
Improve handling of default locale and other locale-related fixes.

See https://github.com/wxWidgets/wxWidgets/pull/2260

Closes #11594.
2021-03-05 18:48:30 +01:00
Vadim Zeitlin
3701baecde Merge branch 'webview_script_message' of https://github.com/TcT2k/wxWidgets
Add WebView script message and user scripts.

See https://github.com/wxWidgets/wxWidgets/pull/2237
2021-03-05 18:44:46 +01:00
Paul Cornett
30637ad3b6 Make wxGridEvent methods GetRow() and GetCol() const and not virtual
See #19085
2021-03-05 07:38:32 -08:00
Paul Cornett
4388b9bd6b Make some member functions const 2021-03-04 11:49:33 -08:00
Tobias Taschner
80c04e3941
Merge branch 'master' into webview_script_message 2021-03-01 09:57:13 +01:00
Vadim Zeitlin
afb57182e1 Merge branch 'gcc-edge'
Make it possible to build wxWebViewEdge with gcc or clang too.

Closes https://github.com/wxWidgets/wxWidgets/pull/2245
2021-03-01 00:09:52 +01:00
Maarten Bent
7532532800 Mention GCC/Clang support in wxWebViewEdge documentation
And add a comment explaining the name of the EventRegistrationToken include guard.
2021-03-01 00:09:23 +01:00
Tobias Taschner
5a30bbe38f
Apply suggestions from code review
Co-authored-by: PB <PBforDev@gmail.com>
2021-02-28 22:33:15 +01:00
Tobias Taschner
f419240335
Add Apple transport security to wxWebView docs 2021-02-28 20:44:38 +01:00
Tobias Taschner
ca5133fff7
Add usage documentation to wxWebView::AddScriptMessageHandler() 2021-02-28 20:41:49 +01:00
Vadim Zeitlin
91ec900034 Explicitly disallow wxLANGUAGE_UNKNOWN in wxLocale::Init()
This value doesn't make here, so be upfront about it.
2021-02-28 20:04:33 +01:00
Tobias Taschner
575ae90d85
Fix trailing whitespace 2021-02-28 20:03:36 +01:00
Tobias Taschner
6f7ac6a934
Add wxWebView::AddUserScript()
This allows to inject javascript code across multiple pages
2021-02-26 23:41:39 +01:00
Tobias Taschner
f2bfa7d446
Initial AddScriptMessageHandler() documentation 2021-02-26 22:35:49 +01:00
Tobias Taschner
b1d558a612
Disabled dev tools per default for Edge
This unifies the behavior among backends and is probably
the more useful default for most applications.
2021-02-26 21:55:10 +01:00
Tobias Taschner
3af4702b11
Implement wxWebView::EnableAccessToDevTools() for GTK 2021-02-26 18:53:46 +01:00
Tobias Taschner
c3d0d7d000
Identify script handler in message event 2021-02-26 16:59:56 +01:00
Tobias Taschner
011035ef08
Add wxEVT_WEBVIEW_SCRIPT_MESSAGE_RECEIVED event 2021-02-26 15:41:41 +01:00
Vadim Zeitlin
2c9f6770a5 Merge branch 'valnum-unsigned'
Fix handling of unsigned types in numeric validators: don't accept
negative numbers as unsigned, allow using the full 64-bit range.

See https://github.com/wxWidgets/wxWidgets/pull/2244

Closes #12967.
2021-02-23 21:52:27 +01:00
Vadim Zeitlin
eb64202ad4 Add support for unsigned long long to wxNumberFormatter
This is necessary in order to deal with the numbers greater than
wxINT64_MAX that can't be represented in just long long.

It also allows to implement the intuitive handling of minus sign for the
unsigned numbers, i.e. not to accept it in FromString(), unlike the
standard functions which do (and parse -1 as 0xffff...fff).

Also extend the tests to check for more boundary cases.
2021-02-22 11:49:19 +01:00
Vadim Zeitlin
b53f7ac904 Restore support for using faster dotted pens in wxMSW
Changes of d245dc9e1f (Fix drawing of dotted lines with wxDC in wxMSW,
2020-03-27) improved the appearance of dotted and dashed lines in wxMSW
but at the expense of significant (up to a factor of 300) slowdown.

Allow the applications for which the drawing performance is important to
explicitly request the old behaviour, with uglier, but faster, pens by
choosing to use low quality pens.

Update the graphics benchmark to allow specifying the pen quality and
verify that the performance when using it is the same as before 3.1.4.

See https://github.com/wxWidgets/wxWidgets/pull/2218

See #7097.

Closes #18875.
2021-02-22 00:04:07 +01:00
Vadim Zeitlin
d3f051e328 Document wxNumberFormatter overloads using long long
These overloads were added back in f2a5052baa (Add support for long long
to wxNumberFormatter., 2011-01-19) but never documented.
2021-02-21 16:43:04 +01:00
Gary Allen
9b1829c300 Add wxRibbon panel border colour option
Add wxRIBBON_ART_PANEL_HOVER_BORDER_COLOUR and
wxRIBBON_ART_PANEL_HOVER_BORDER_GRADIENT_COLOUR to allow further
customization of wxRibbon panels.

Closes https://github.com/wxWidgets/wxWidgets/pull/2239
2021-02-20 13:29:33 +01:00
Dimitri Schoolwerth
40422db37d Add wxMac wxFileDialog::GetCurrentlySelectedFilterIndex() support
Simply set the relevant variable while changing selection and give
the extra control a chance to update.

Note that updating the UI currently asserts with the dialog sample if
wxOSX_FILEDIALOG_ALWAYS_SHOW_TYPES is 1 (toggable with Ctrl+Cmd+S in
the sample), This will be fixed in the next commit.
2021-02-15 00:37:45 +01:00
Tobias Taschner
e09063186c
Provide generic wxWebView::Find() implementation
This implementation is based on javascript 'window.find()'
https://developer.mozilla.org/en-US/docs/Web/API/Window/find
It's not standard, but implemented in most browsers.

It's not a complete implementation as it can't determine how
many search results can be found.

If the backends API provides a native find interface it should be
used instead of this implementation, but it's good fallback.
2021-02-10 23:55:18 +01:00
Tobias Taschner
5512089d5b
Apply suggestions from code review
Co-authored-by: VZ <vz-github@zeitlins.org>
2021-02-09 23:35:01 +01:00
Tobias Taschner
a3f85e9cd5
Implement wxEVT_WEBVIEW_FULLSCREEN_CHANGED in GTK 2021-02-09 22:28:29 +01:00
Tobias Taschner
f6a23a0431
Add wxEVT_WEBVIEW_FULLSCREEN_CHANGED event
The event is triggered by wxWebView when the page requests fullscreen view.

It's currently only implemented for the edge backend.
2021-02-09 22:28:29 +01:00
Vadim Zeitlin
7a74c0872c Merge branch 'msw_webview_edge3' of https://github.com/TcT2k/wxWidgets
Make using wxWebViewEdge even simpler in CMake builds.

See https://github.com/wxWidgets/wxWidgets/pull/2223
2021-02-09 15:22:56 +01:00
Vadim Zeitlin
f2d5ff0121 Make wxNumValidator::m_value protected rather than private
This is useful for writing overridden TransferXXX() methods in the
derived validator classes, give a motivating example in the docs.

See https://github.com/wxWidgets/wxWidgets/pull/2222
2021-02-08 22:43:48 +01:00
Tobias Taschner
1ee05c54ed
CMake: Download SDK when wxUSE_WEBVIEW_EDGE=ON
Automatically download the WebView2 SDK from nuget (official repo for the SDK)
when enabling wxUSE_WEBVIEW_EDGE to simplify usage.
Copying to 3rdparty/webview2 is still supported optionally.
2021-02-08 21:29:08 +01:00
Vadim Zeitlin
26eb738562 Merge branch 'drop-msw-it.po'
Remove platform-specific translations.

This is unnecessarily complicated for the single string that we
currently use this for, so just handle it specially.

Also some other minor translation-related improvements.

See https://github.com/wxWidgets/wxWidgets/pull/2213
2021-02-08 12:50:43 +01:00
Dimitri Schoolwerth
cc239f36cc Remove doc warning regarding wxGrid multicells and deletion
Since the parent commit multicells work correctly when deleting (and
inserting) rows (or columns) intersecting with them and the comment
warning about it resulting in a crash is no longer needed.

This reverts commit 4d8e8355b4 (Added a warning about multi-cells in
wxGrid::DeleteRows() docs., 2011-12-25).

See #4238.
2021-02-07 22:59:02 +01:00
Vadim Zeitlin
8293dcedef Factor out platform detection from XRC code into wxPlatformId
This will allow reusing the same strings in other places.

Also use this as opportunity to add "msw" as the (preferred) synonym for
"win" for general consistency.
2021-02-06 14:58:09 +01:00
Tobias Taschner
d17e8978a6
Make wxWebView::RunScript() const 2021-02-05 22:18:31 +01:00
Tobias Taschner
788bef2cf2
Select Edge as the default backend on MSW
If enabled and available at runtime use the Edge backend.
This is probably more useful for most users.
2021-02-05 22:18:29 +01:00
Tobias Taschner
b351e7762d
Move common wxWebView code to base class
Removes duplicate code in the various webview backends
2021-02-05 22:18:29 +01:00
Tobias Taschner
0d82348328
Add wxWebView::GetBackendVersionInfo()
Allows to get the WebView backend version if available
Currently implemented for IE, Edge and webkit2.
2021-02-05 22:18:28 +01:00
Tobias Taschner
489afb3336
Allow using a fixed version with wxWebViewEdge
A fixed version may be distributed with the application
and wxWebViewEdge::MSWSetBrowserExecutableDir() allows
it's usage with wxWebViewEdge.
2021-02-05 22:18:28 +01:00
Vadim Zeitlin
a8d869f2c8 Merge branch 'docs/avoid-recommending-wxNewId' of https://github.com/catalinr/wxWidgets
Fixes for wxNewId() documentation.

See https://github.com/wxWidgets/wxWidgets/pull/2211
2021-02-05 21:38:16 +01:00
Gary Allen
f4172b0b46 Allow overriding wxMenu::MSWCommand() in wxMSW
This can be useful to implement custom handling of WM_COMMAND for the
popup menus, so make this function virtual and document it to indicate
that it is now part of the public API.

Closes https://github.com/wxWidgets/wxWidgets/pull/2170
2021-02-05 12:04:25 +01:00
catalinr
bfa4dd01d7 Link wxNewId() with wxRegisterId() in the docs 2021-02-03 12:20:07 +02:00
Paul Cornett
d932e89d40 Document when wxColour::IsSolid() was added 2021-01-28 07:31:36 -08:00
Vadim Zeitlin
97eecc1cce Merge branch 'sizerflags-center-align'
Fix combining wxSizerFlags alignment and CenterXXX().

See https://github.com/wxWidgets/wxWidgets/pull/2190
2021-01-27 17:55:18 +01:00
Vadim Zeitlin
9130f8bfc6 Don't change orthogonal alignment in wxSizerFlags::CenterXXX()
It was unexpected that using wxSizerFlags().Right().CentreVertical()
didn't right-align the item because CentreVertical() reset the alignment
in the horizontal direction rather than just setting it in the vertical
one, so change this, document the new behaviour explicitly and add a new
unit test checking for it.

Closes #18989.
2021-01-25 12:58:04 +01:00
Vadim Zeitlin
4de8857c85 Add wxDynamicLibrary::Attach()
This is symmetric with Detach() and can be useful and doesn't cost
anything to have.
2021-01-25 00:15:24 +01:00
PB
e094734a89 Fix numbered list in wxMenuEvent docs
Just remove the empty line which prevented doxygen from generating a numbered list.
2021-01-24 21:58:59 +01:00
Tobias Taschner
457b213315
Apply suggestions from code review
Co-authored-by: VZ <vz-github@zeitlins.org>
2021-01-19 21:06:31 +01:00
Tobias Taschner
d66b70f224
Add a description of Apple Transport Security to wxWebRequest doc 2021-01-19 15:20:09 +01:00
Tobias Taschner
036b7f29a7
Add wxWebRequest::DisablePeerVerify()
This method allows insecure HTTPS connections when required
2021-01-19 13:16:25 +01:00
Tobias Taschner
bf1b0716e0
Add a note to use wxWebRequest in wxHTTP docs 2021-01-19 13:00:20 +01:00
Vadim Zeitlin
febd185fc6 Merge branch 'web-request'
Add wxWebViewRequest and related classes allowing to use HTTPS and
HTTP/2.

See https://github.com/wxWidgets/wxWidgets/pull/977
2021-01-17 18:19:47 +01:00
Vadim Zeitlin
4a7b6d7e8f Document that index must be valid in wxChoice::GetString()
This is now the case in all ports, and not just in wxOSX, so document
this behaviour and also document that it has changed compared to 3.0.
2021-01-17 00:41:26 +01:00
Vadim Zeitlin
717e6590bd Merge branch 'macos_wkwebview' of https://github.com/TcT2k/wxWidgets
Use WKWebView for wxWebView Implementation under Apple systems.

See https://github.com/wxWidgets/wxWidgets/pull/2113
2021-01-16 16:20:58 +01:00
Vadim Zeitlin
1065e61ab7 Merge branch 'log-ms'
Use milliseconds in wxLog timestamps.

See https://github.com/wxWidgets/wxWidgets/pull/2164
2021-01-16 16:00:57 +01:00
Vadim Zeitlin
3241c443c5 Process event about the request becoming active synchronously
This is required in order to allow doing something with the request when
it already have a valid native handle, but hasn't actually started yet.
2021-01-16 14:59:41 +01:00
Vadim Zeitlin
508a4f6ca8 Fix Cancel() semantics under MSW and other improvements to it
Under MSW, don't set the state to State_Cancelled as soon as Cancel()
was called, as the request was still used from the other threads
afterwards, resulting in race conditions and crashes.

Fix this by just removing the SetState(State_Cancelled) call from the
main thread, as it was redundant anyhow. This also makes the behaviour
correspond to the documentation, which indicates that Cancel() works
asynchronously.

Also ensure, for all backends, that we actually cancel the request only
once, even if public Cancel() is called multiple times. This required
renaming the existing wxWebRequestImpl::Cancel() to DoCancel().
2021-01-16 13:50:29 +01:00
Vadim Zeitlin
65aad890e3 Add GetNativeHandle() to wxWebSession and wxWebRequest
This allows to retrieve the handles used internally in order to do
something not supported by the public API yet.
2021-01-16 00:21:00 +01:00
Vadim Zeitlin
e6cedf6649 Really support milliseconds in wxLog
Although this was supposed to work, specifying "%l" in wxLog time stamp
format actually didn't because wxLog timestamps were stored as seconds.

Fix this by storing them as milliseconds and add a simple test (not
executed by default) showing that "%l" works correctly now.

Still keep the old wxLogRecordInfo::timestamp field for compatibility,
as it was documented.

See #13059.
2021-01-15 14:55:06 +01:00
Vadim Zeitlin
ef08d499ce Remove unnecessary SetIgnoreServerErrorStatus() from the API
It's up to the application code to decide how it handles the HTTP status
codes it gets back from server, there is no need to have a special
method for handling them in wxWebRequest itself.

We also shouldn't skip downloading the response body just because it was
unsuccessful, we may still need it (e.g. it's very common to return the
detailed error description in a JSON object in the message body when
returning some 4xx error), so don't do it in wxMSW implementation and
add a test verifying that we still get the expected body even for an
error status.

Also improve wxWebRequest::State values documentation.
2021-01-15 03:08:18 +01:00
Dominic Letz
156045b73b Use consistent event names in wxNotificationMessage documentation
Follow the convention of using the event macro names (rather than the
event type) names in @event documentation in wxNotificationMessage
documentation too, e.g. use EVT_NOTIFICATION_MESSAGE_CLICK rather than
wxEVT_NOTIFICATION_MESSAGE_CLICK.

Closes https://github.com/wxWidgets/wxWidgets/pull/2166
2021-01-14 18:25:56 +01:00
Vadim Zeitlin
20a3317839 Rename wxWebRequestEvent::GetResponseFileName() to GetDataFile()
This is shorter and doesn't imply that just the name (and not the full
path) is being returned.

Also rename wxWebResponse::GetFileName() to GetDataFile() for the same
reasons and for consistency. And document this previously undocumented
method.
2021-01-12 03:34:40 +01:00
Vadim Zeitlin
d0f56b1d04 Document wxWebResponse::GetContentLength()
Also change its return type from wxInt64 to wxFileOffset for consistency
with all the other length/progress-related functions in wxWebRequest.
2021-01-12 03:25:16 +01:00
Vadim Zeitlin
3da03b3b7b Clarify values returned by wxWebRequest progress methods
Make it clear which values change and which remain constant.
2021-01-12 03:14:18 +01:00
Vadim Zeitlin
67ad831a31 Improve documentation of wxWebRequest storage methods
Indicate which methods should be used with each storage type to process
the data later.
2021-01-12 03:09:51 +01:00
Vadim Zeitlin
5713d17ab0 Clarify asynchronous nature of wxWebRequest::Cancel() in the docs 2021-01-12 02:30:33 +01:00
Vadim Zeitlin
dceb24ad7c Add support for WXWEBREQUEST_BACKEND environment variable
Defining this variable overrides the default backend choice.

Document the variable itself and also extend wxWebSession::New()
documentation.
2021-01-12 02:17:39 +01:00
Robin Dunn
0df1d81acd Add missing wxDF_PNG to the interface docs 2021-01-11 12:27:30 -08:00
Vadim Zeitlin
4986850c63 Rename wxWebSession::SetHeader() to AddCommonHeader()
The old name wasn't very clear and it was confusing to have methods with
the same name in wxWebSession and wxWebRequest.
2021-01-11 03:02:25 +01:00
Vadim Zeitlin
054892f250 Fix wording of wxWebRequestEvent::GetResponseFileName() docs
Also document that the returned string is the full path and not just the
name of the file.
2021-01-11 02:54:48 +01:00
Vadim Zeitlin
451b97170b Small tweak to wxCredentialEntryDialog docs consistency
Don't use the article for just one parameter.
2021-01-11 02:51:05 +01:00
Vadim Zeitlin
abcc31c6b2 Update wxCredentialEntryDialog to use wxWebCredentials
As a side effect, make wxWebCredentials default-constructible.

Also demonstrate using wxCredentialEntryDialog in the sample.
2021-01-10 21:27:15 +01:00
Vadim Zeitlin
1e6d6be8bb Add wxWebCredentials and use it in SetCredentials()
Prefer using a class encapsulating both the user name and the password
to using a pair of variables.
2021-01-10 21:27:15 +01:00
Gary Allen
027c1b8304 Update wxRibbonToolBar docs 2021-01-10 20:18:42 +02:00
Vadim Zeitlin
fe197d7527 Add small wxSecretString helper for wiping strings values
This is simpler and more robust than remembering to call WipeString()
manually.
2021-01-10 01:21:45 +01:00
Vadim Zeitlin
5d236edeed Ensure wxWebRequest is in idle state before starting it
Check that current state is State_Idle in wxWebRequest itself only once
instead of doing it in 2 (out of 3) wxWebRequestImpl implementations.

Also assert if this is not the case instead of silently doing nothing
which would surely be more difficult to debug.
2021-01-09 21:00:38 +01:00
Vadim Zeitlin
989cafe535 Take raw pointer and not wxSharedPtr<> in SetData()
Using shared pointer seems to be ill-advised here, the stream shouldn't
be shared as it's going to be used by wxWebRequest itself and can't be
used by the application code in parallel, so the ownership transfer
semantics is more appropriate.

We could take a wxScopedPtr<> instead, but wx API takes ownership of raw
pointers everywhere else, so do it here too.

Incidentally fix a bug with calling IsOk() on a possibly null pointer.
2021-01-04 01:57:36 +01:00
Vadim Zeitlin
b58ee58a7b Update copyright years to 2021
Just run misc/scripts/inc_year and commit the results.

See #18690.
2021-01-03 18:12:37 +01:00