Compare commits

...

9 Commits

Author SHA1 Message Date
Lea Anthony
ff666379fd Merge branch '261-korean-fonts' of github.com:wailsapp/wails into 261-korean-fonts 2019-10-25 18:11:52 +11:00
Lea Anthony
69000a0afb fix: re-add webview_set_title 2019-10-25 18:10:25 +11:00
Lea Anthony
dd43737b82 merge develop 2019-10-25 17:42:34 +11:00
Lea Anthony
061c3a6cca Merge branch 'develop' into 261-korean-fonts 2019-10-25 12:25:22 +11:00
Lea Anthony
226b02646b fix: unicode text for Windows 2019-10-25 12:24:20 +11:00
Lea Anthony
2e9e6a398a chore: bump version 2019-10-24 08:53:54 +11:00
Lea Anthony
cd3865038b fix: linting 2019-10-24 08:52:43 +11:00
Lea Anthony
9e6d6763ec Merge branch 'develop' into 261-korean-fonts 2019-10-23 21:37:13 +11:00
Lea Anthony
e0856b8bfc fix: detect encoding on windows 2019-10-23 21:29:40 +11:00
2 changed files with 16 additions and 0 deletions

View File

@@ -20,3 +20,4 @@ Wails is what it is because of the time and effort given by these great people.
* [Toyam Cox](https://github.com/Vaelatern)
* [Robin Eklind](https://github.com/mewmew)
* [Kris Raney](https://github.com/kraney)
* [soon cheol shin](https://github.com/scshin0572)

View File

@@ -217,6 +217,21 @@ struct webview_priv
va_end(ap);
}
WEBVIEW_API void webview_set_title(struct webview *w, const char *title)
{
#ifdef UNICODE
wchar_t *u16title = webview_to_utf16(title);
if (u16title == NULL)
{
return;
}
SetWindowText(w->priv.hwnd, u16title);
GlobalFree(u16title);
#else
SetWindowText(w->priv.hwnd, title);
#endif
}
static int webview_js_encode(const char *s, char *esc, size_t n)
{
int r = 1; /* At least one byte for trailing zero */