Skip to content

Commit

Permalink
🏗️ implement base getUrl for Swing WebWrapper
Browse files Browse the repository at this point in the history
  • Loading branch information
teras committed Oct 24, 2020
1 parent 34151a0 commit f1ffe5e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public void draw(SwingGraphicsContext cx) {

public interface DesktopNativeWidget extends NativeWrapper<SwingGraphicsContext>, SizableComponent {

WidgetWrapper getWrapper();
WidgetWrapper<?, ?, ?> getWrapper();

void dispatchEvent(AWTEvent originalEvent);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,13 @@ public WKNavigation loadData(String data, String MIMEType, String baseURL) {
ntv.setDocument(ntv.getEditorKit().createDefaultDocument());
ntv.setContentType(MIMEType);
ntv.setText(data);
return null;
return getNavigation(baseURL);
}

@Override
public WKNavigation reload() {
Native.system().notImplemented();
return null;
return getNavigation(getUrl());
}

@Override
Expand All @@ -91,14 +91,12 @@ public void stopLoading() {

@Override
public String getTitle() {
Native.system().notImplemented();
return null;
return "";
}

@Override
public String getUrl() {
Native.system().notImplemented();
return null;
return getNativeWidget().getPage().toString();
}

@Override
Expand Down

0 comments on commit f1ffe5e

Please sign in to comment.