fixed opening vk id and bugtracker
This commit is contained in:
@@ -136,7 +136,7 @@ public class VTSettings extends MaterialPreferenceToolbarFragment {
|
||||
|
||||
PreferencesUtil.addPreference(this, "", Globals.getString("vkconnect"), "", oldicons() ? "ic_tags_24" : "ic_user_circle_outline_28", preference -> {
|
||||
Context context = getContext();
|
||||
VKUIwrapper.setLink("https://id.vk.com/account");
|
||||
VKUIwrapper.officalLinks("account");
|
||||
Intent a2 = new Navigator(VKUIwrapper.class).b(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
@@ -158,7 +158,8 @@ public class VTSettings extends MaterialPreferenceToolbarFragment {
|
||||
|
||||
PreferencesUtil.addPreference(this, "", Globals.getString("bugs"), "", oldicons() ? "ic_bug_24" : "ic_bug_outline_28", preference -> {
|
||||
Context context = getContext();
|
||||
Intent a2 = new Navigator(BugtrackerFragment.class).b(context);
|
||||
VKUIwrapper.officalLinks("bugs");
|
||||
Intent a2 = new Navigator(VKUIwrapper.class).b(context);
|
||||
context.startActivity(a2);
|
||||
return false;
|
||||
});
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
package ru.vtosters.lite.utils;
|
||||
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
|
||||
import com.vk.core.util.LangUtils;
|
||||
import com.vk.core.util.UriExt;
|
||||
import com.vk.webapp.VkUiFragment;
|
||||
|
||||
public final class VKUIwrapper extends VkUiFragment {
|
||||
@@ -16,4 +19,10 @@ public final class VKUIwrapper extends VkUiFragment {
|
||||
public static void setLink(String getlink){
|
||||
link = getlink;
|
||||
}
|
||||
|
||||
public static void officalLinks(String getlink){
|
||||
Uri.Builder appendPath = new Uri.Builder().scheme("https").authority(VkUiFragment.z0.a()).appendPath(getlink);
|
||||
Uri.Builder appendQueryParameter = UriExt.a(appendPath).appendQueryParameter("lang", LangUtils.a());
|
||||
link = appendQueryParameter.build().toString();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user