Skip to content

Commit

Permalink
1.8.1
Browse files Browse the repository at this point in the history
  • Loading branch information
tuarua committed Aug 3, 2018
1 parent fa1c601 commit f3fa74b
Show file tree
Hide file tree
Showing 12 changed files with 35 additions and 31 deletions.
5 changes: 4 additions & 1 deletion CHANGELOG.md
@@ -1,3 +1,6 @@
### 1.8.1
- WIN: WKWebview download implementation [Issue #168](https://github.com/tuarua/WebViewANE/issues/168)

### 1.8.0
- OSX/iOS: Updated to FreSwift 2.5.0
- AND: Updated to FreKotlin 1.4.0
Expand All @@ -6,7 +9,7 @@

### 1.7.0
- WIN: Updated to CefSharp 65.0.0 pre-rel
- WIN: UTF-8 bug Issue #155
- WIN: UTF-8 bug [Issue #155](https://github.com/tuarua/WebViewANE/issues/155)
- WIN: Remove MSVC2013 as a dependency
- WIN: Updated to FreSharp 1.6.0
- WIN: Added basic support for Modern WebView (Edge)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -8,7 +8,7 @@ This ANE provides access to a more modern webview from AIR.
[![paypal](https://www.paypalobjects.com/en_US/i/btn/btn_donateCC_LG.gif)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=5UR2T52J633RC)

##### Much time, skill and effort has gone into this. Join these people in helping support the project
[Multimedia Plus](http://www.multimediaplus.com), [MediaSignage inc](http://www.digitalsignage.com), [Maretron](https://www.maretron.com/), Dignora Perez, Thomas Wooldridge, Gustavo Fantini, Mark Hemphill, Tim John, George Perry, Fernando Ramon Macías Ceballos, 谭 海彬, Bry Birey Egitim, Tomas Redondo, Ilkhom Khodjaev, Argonaut Design
[Multimedia Plus](http://www.multimediaplus.com), [MediaSignage inc](http://www.digitalsignage.com), [Maretron](https://www.maretron.com/), [Showfit](http://showfit.com/), Dignora Perez, Thomas Wooldridge, Gustavo Fantini, Mark Hemphill, Tim John, George Perry, Fernando Ramon Macías Ceballos, 谭 海彬, Bry Birey Egitim, Tomas Redondo, Ilkhom Khodjaev, Argonaut Design

##### IDE Software provided by JetBrains
[![Jetbrains](https://raw.githubusercontent.com/tuarua/WebViewANE/master/screenshots/jetbrains.png)](https://www.jetbrains.com)
Expand Down
Binary file modified c_sharp_libs_x64/WebViewANELib.dll
Binary file not shown.
Binary file modified c_sharp_libs_x86/WebViewANELib.dll
Binary file not shown.
2 changes: 1 addition & 1 deletion native_extension/ane/extension_android.xml
Expand Up @@ -3,7 +3,7 @@
<id>com.tuarua.WebViewANE</id>
<name>WebView ANE</name>
<copyright>This work is licensed under Apache License, Copyright (c) 2018 Tua Rua Ltd.</copyright>
<versionNumber>1.8.0</versionNumber>
<versionNumber>1.8.1</versionNumber>
<platforms>
<platform name="Android-ARM">
<applicationDeployment>
Expand Down
2 changes: 1 addition & 1 deletion native_extension/ane/extension_ios.xml
Expand Up @@ -3,7 +3,7 @@
<id>com.tuarua.WebViewANE</id>
<name>WebView ANE</name>
<copyright>This work is licensed under Apache License, Copyright (c) 2018 Tua Rua Ltd.</copyright>
<versionNumber>1.8.0</versionNumber>
<versionNumber>1.8.1</versionNumber>
<platforms>
<platform name="iPhone-x86">
<applicationDeployment>
Expand Down
2 changes: 1 addition & 1 deletion native_extension/ane/extension_multi.xml
Expand Up @@ -3,7 +3,7 @@
<id>com.tuarua.WebViewANE</id>
<name>WebView ANE</name>
<copyright>This work is licensed under Apache License, Copyright (c) 2018 Tua Rua Ltd.</copyright>
<versionNumber>1.8.0</versionNumber>
<versionNumber>1.8.1</versionNumber>
<platforms>
<platform name="iPhone-x86">
<applicationDeployment>
Expand Down
2 changes: 1 addition & 1 deletion native_extension/ane/extension_osx.xml
Expand Up @@ -3,7 +3,7 @@
<id>com.tuarua.WebViewANE</id>
<name>WebView ANE</name>
<copyright>This work is licensed under Apache License, Copyright (c) 2018 Tua Rua Ltd.</copyright>
<versionNumber>1.8.0</versionNumber>
<versionNumber>1.8.1</versionNumber>
<platforms>
<platform name="MacOS-x86-64">
<applicationDeployment>
Expand Down
2 changes: 1 addition & 1 deletion native_extension/ane/extension_win.xml
Expand Up @@ -3,7 +3,7 @@
<id>com.tuarua.WebViewANE</id>
<name>WebView ANE</name>
<copyright>This work is licensed under Apache License, Copyright (c) 2018 Tua Rua Ltd.</copyright>
<versionNumber>1.8.0</versionNumber>
<versionNumber>1.8.1</versionNumber>
<platforms>
<platform name="Windows-x86">
<applicationDeployment>
Expand Down
Binary file modified native_extension/ane/platforms/win/x64/release/WebViewANE.dll
Binary file not shown.
Binary file modified native_extension/ane/platforms/win/x86/release/WebViewANE.dll
Binary file not shown.
Expand Up @@ -185,7 +185,7 @@ public class MainController : FreSharpMainController {
"Please see https://forum.starling-framework.org/topic/webviewane-for-osx/page/7?replies=201#post-105524 for more details")
.RawValue;
}

System.Windows.Media.Color backgroundMediaColor;
try {
var viewPort = argv[1].AsRect();
var settingsFre = argv[2];
Expand All @@ -208,38 +208,26 @@ public class MainController : FreSharpMainController {
var whiteList = settingsFre.GetProp("urlWhiteList").ToArrayList();
var blackList = settingsFre.GetProp("urlBlackList").ToArrayList();
_backgroundColor = colorFre.AsColor(true);

backgroundMediaColor = new System.Windows.Media.Color {
A = _backgroundColor.A,
R = _backgroundColor.R,
G = _backgroundColor.G,
B = _backgroundColor.B
};

_scaleFactor = useHiDpi ? WinApi.GetScaleFactor() : 1.0;

if (_useEdge) {
EdgeView.Context = Context;
_view = new EdgeView {
InitialUrl = argv[0].AsString(),
Background = new SolidColorBrush(new System.Windows.Media.Color {
A = _backgroundColor.A,
R = _backgroundColor.R,
G = _backgroundColor.G,
B = _backgroundColor.B
}),
X = Convert.ToInt32(viewPort.X * _scaleFactor),
Y = Convert.ToInt32(viewPort.Y * _scaleFactor),
ViewWidth = Convert.ToInt32(viewPort.Width * _scaleFactor),
ViewHeight = Convert.ToInt32(viewPort.Height * _scaleFactor)
Background = new SolidColorBrush(backgroundMediaColor)
};
}
else {
CefView.Context = Context;
_view = new CefView {
InitialUrl = argv[0].AsString(),
Background = new SolidColorBrush(new System.Windows.Media.Color {
A = _backgroundColor.A,
R = _backgroundColor.R,
G = _backgroundColor.G,
B = _backgroundColor.B
}),
X = Convert.ToInt32(viewPort.X * _scaleFactor),
Y = Convert.ToInt32(viewPort.Y * _scaleFactor),
ViewWidth = Convert.ToInt32(viewPort.Width * _scaleFactor),
ViewHeight = Convert.ToInt32(viewPort.Height * _scaleFactor),
Background = new SolidColorBrush(backgroundMediaColor),
RemoteDebuggingPort = cefSettingsFre.GetProp("remoteDebuggingPort").AsInt(),
CachePath = cefSettingsFre.GetProp("cachePath").AsString(),
DownloadPath = settingsFre.GetProp("downloadPath").AsString(),
Expand All @@ -260,6 +248,11 @@ public class MainController : FreSharpMainController {
)
};
}
_view.InitialUrl = argv[0].AsString();
_view.X = Convert.ToInt32(viewPort.X * _scaleFactor);
_view.Y = Convert.ToInt32(viewPort.Y * _scaleFactor);
_view.ViewWidth = Convert.ToInt32(viewPort.Width * _scaleFactor);
_view.ViewHeight = Convert.ToInt32(viewPort.Height * _scaleFactor);
_view.Init();
}
catch (Exception e) {
Expand All @@ -273,9 +266,17 @@ public class MainController : FreSharpMainController {
parameters.WindowName = "Cef Window";
parameters.WindowStyle = (int) WindowStyles.WS_CHILD;
parameters.AcquireHwndFocusInMenuMode = true;

if (Environment.OSVersion.Version.Major > 7) {
parameters.ExtendedWindowStyle = (int) WindowExStyles.WS_EX_LAYERED;
parameters.UsesPerPixelTransparency = true;
}

var source = _useEdge ? new HwndSource(parameters) {RootVisual = (EdgeView) _view}
: new HwndSource(parameters) {RootVisual = (CefView) _view};

if (source.CompositionTarget != null) {
source.CompositionTarget.BackgroundColor = backgroundMediaColor;
}
_webViewWindow = source.Handle;

WinApi.RegisterTouchWindow(_webViewWindow, TouchWindowFlags.TWF_WANTPALM);
Expand Down

0 comments on commit f3fa74b

Please sign in to comment.