update tutorial url

This commit is contained in:
hyb1996 2018-02-01 14:28:16 +08:00
parent 1205fc08e3
commit a06fca1971
3 changed files with 7 additions and 4 deletions

View File

@ -138,7 +138,7 @@ public class Pref {
if (docSource == null || docSource.equals("Local")) {
return "file:///android_asset/docs/";
} else {
return "https://hyb1996.github.io/AutoJs-Docs/";
return "https://www.autojs.org/assets/autojs/docs/";
}
}

View File

@ -1,7 +1,6 @@
package com.stardust.scriptdroid.ui.main.drawer;
import android.content.Intent;
import android.graphics.Color;
import android.graphics.drawable.Drawable;
import android.os.Build;
import android.os.Bundle;
@ -73,7 +72,7 @@ import io.reactivex.schedulers.Schedulers;
@EFragment(R.layout.fragment_drawer)
public class DrawerFragment extends android.support.v4.app.Fragment {
private static final String URL_SUBLIME_PLUGIN_HELP = "https://github.com/hyb1996/AutoJs-Sublime-Plugin/blob/master/Readme.md";
private static final String URL_DEV_PLUGIN = "https://www.autojs.org/topic/968/";
@ViewById(R.id.header)
View mHeaderView;
@ -247,7 +246,7 @@ public class DrawerFragment extends android.support.v4.app.Fragment {
.neutralText(R.string.text_help)
.onNeutral((dialog, which) -> {
setChecked(mConnectionItem, false);
IntentUtil.browse(getActivity(), URL_SUBLIME_PLUGIN_HELP);
IntentUtil.browse(getActivity(), URL_DEV_PLUGIN);
})
.cancelListener(dialog -> setChecked(mConnectionItem, false))
.show();

View File

@ -169,6 +169,10 @@ public class UiSelector extends UiGlobalSelector {
return uiObjectCollection.get(0);
}
public UiObject findOnce() {
return findOnce(0);
}
public UiObject findOnce(int index) {
UiObjectCollection uiObjectCollection = find();
while (uiObjectCollection.empty()) {