Commit 53e9ecbf authored by pichillilorenzo's avatar pichillilorenzo

v0.5.4, updated docs and README.md

parent 305c7262
This diff is collapsed.
...@@ -382,7 +382,7 @@ inAppWebViewController.goBack(); ...@@ -382,7 +382,7 @@ inAppWebViewController.goBack();
#### Future\<bool\> InAppWebViewController.canGoBack #### Future\<bool\> InAppWebViewController.canGoBack
Returns a Boolean value indicating whether the `InAppWebView` can move backward. Returns a boolean value indicating whether the `InAppWebView` can move backward.
```dart ```dart
inAppWebViewController.canGoBack(); inAppWebViewController.canGoBack();
...@@ -398,12 +398,36 @@ inAppWebViewController.goForward(); ...@@ -398,12 +398,36 @@ inAppWebViewController.goForward();
#### Future\<bool\> InAppWebViewController.canGoForward #### Future\<bool\> InAppWebViewController.canGoForward
Returns a Boolean value indicating whether the `InAppWebView` can move forward. Returns a boolean value indicating whether the `InAppWebView` can move forward.
```dart ```dart
inAppWebViewController.canGoForward(); inAppWebViewController.canGoForward();
``` ```
#### Future\<void\> InAppWebViewController.goBackOrForward
Goes to the history item that is the number of steps away from the current item. Steps is negative if backward and positive if forward.
```dart
inAppWebViewController.goBackOrForward(int steps);
```
#### Future\<bool\> InAppWebViewController.canGoBackOrForward
Returns a boolean value indicating whether the `InAppWebView` can go back or forward the given number of steps. Steps is negative if backward and positive if forward.
```dart
inAppWebViewController.canGoBackOrForward(int steps);
```
#### Future\<void\> InAppWebViewController.goTo
Navigates to a `WebHistoryItem` from the back-forward `WebHistory.list` and sets it as the current item.
```dart
inAppWebViewController.goTo(WebHistoryItem historyItem);
```
#### Future\<bool\> InAppWebViewController.isLoading #### Future\<bool\> InAppWebViewController.isLoading
Check if the Web View of the `InAppWebView` instance is in a loading state. Check if the Web View of the `InAppWebView` instance is in a loading state.
...@@ -498,6 +522,16 @@ Gets the current `InAppWebView` options. Returns `null` if the options are not s ...@@ -498,6 +522,16 @@ Gets the current `InAppWebView` options. Returns `null` if the options are not s
inAppWebViewController.getOptions(); inAppWebViewController.getOptions();
``` ```
#### Future\<WebHistory\> InAppWebViewController.getCopyBackForwardList
Gets the WebHistory for this WebView. This contains the back/forward list for use in querying each item in the history stack.
This contains only a snapshot of the current state.
Multiple calls to this method may return different objects.
The object returned from this method will not be updated to reflect any new state.
```dart
inAppWebViewController.getCopyBackForwardList();
```
### `InAppBrowser` class ### `InAppBrowser` class
In-App Browser using native WebView. In-App Browser using native WebView.
......
...@@ -873,7 +873,7 @@ class InAppWebViewController { ...@@ -873,7 +873,7 @@ class InAppWebViewController {
await _channel.invokeMethod('goBack', args); await _channel.invokeMethod('goBack', args);
} }
///Returns a Boolean value indicating whether the [InAppWebView] can move backward. ///Returns a boolean value indicating whether the [InAppWebView] can move backward.
Future<bool> canGoBack() async { Future<bool> canGoBack() async {
Map<String, dynamic> args = <String, dynamic>{}; Map<String, dynamic> args = <String, dynamic>{};
if (_inAppBrowserUuid != null) { if (_inAppBrowserUuid != null) {
...@@ -893,7 +893,7 @@ class InAppWebViewController { ...@@ -893,7 +893,7 @@ class InAppWebViewController {
await _channel.invokeMethod('goForward', args); await _channel.invokeMethod('goForward', args);
} }
///Returns a Boolean value indicating whether the [InAppWebView] can move forward. ///Returns a boolean value indicating whether the [InAppWebView] can move forward.
Future<bool> canGoForward() async { Future<bool> canGoForward() async {
Map<String, dynamic> args = <String, dynamic>{}; Map<String, dynamic> args = <String, dynamic>{};
if (_inAppBrowserUuid != null) { if (_inAppBrowserUuid != null) {
...@@ -916,7 +916,7 @@ class InAppWebViewController { ...@@ -916,7 +916,7 @@ class InAppWebViewController {
await _channel.invokeMethod('goBackOrForward', args); await _channel.invokeMethod('goBackOrForward', args);
} }
///Gets whether the page can go back or forward the given number of steps. ///Returns a boolean value indicating whether the [InAppWebView] can go back or forward the given number of steps. Steps is negative if backward and positive if forward.
Future<bool> canGoBackOrForward(int steps) async { Future<bool> canGoBackOrForward(int steps) async {
assert(steps != null); assert(steps != null);
...@@ -929,7 +929,7 @@ class InAppWebViewController { ...@@ -929,7 +929,7 @@ class InAppWebViewController {
return await _channel.invokeMethod('canGoBackOrForward', args); return await _channel.invokeMethod('canGoBackOrForward', args);
} }
///Navigates to an item from the back-forward list and sets it as the current item. ///Navigates to a [WebHistoryItem] from the back-forward [WebHistory.list] and sets it as the current item.
Future<void> goTo(WebHistoryItem historyItem) async { Future<void> goTo(WebHistoryItem historyItem) async {
await goBackOrForward(historyItem.offset); await goBackOrForward(historyItem.offset);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment