chrome-custom-tabs

Android- EXTRA_HEADERS is not reflecting in updated Chrome version greater than 83

余生长醉 提交于 2020-08-20 06:29:52
问题 Earlier the EXTRA_HEADERS passed to the customTabsIntent.intent.putExtra(Browser.EXTRA_HEADERS, headers), was working fine. After Chrome updated to 83, it stopped passing the header data. public static void startCustomTab(String url, Context context) { CustomTabsIntent.Builder builder = new CustomTabsIntent.Builder(); CustomTabsIntent customTabsIntent = builder.build(); builder.setShowTitle(true); Bundle headers = new Bundle(); headers.putString(context.getString(R.string.type), "android");

Android- EXTRA_HEADERS is not reflecting in updated Chrome version greater than 83

China☆狼群 提交于 2020-08-20 06:29:07
问题 Earlier the EXTRA_HEADERS passed to the customTabsIntent.intent.putExtra(Browser.EXTRA_HEADERS, headers), was working fine. After Chrome updated to 83, it stopped passing the header data. public static void startCustomTab(String url, Context context) { CustomTabsIntent.Builder builder = new CustomTabsIntent.Builder(); CustomTabsIntent customTabsIntent = builder.build(); builder.setShowTitle(true); Bundle headers = new Bundle(); headers.putString(context.getString(R.string.type), "android");

How to add EXTRA_REFERRER to CustomTabsIntent builder in Chrome custom tab for Android

谁都会走 提交于 2020-08-05 05:34:18
问题 I am using newly launched Chrome Custom tabs for android instead of using webviews. This is the link to their documentation Here is the code that shows how to use it. String url = ¨https://paul.kinlan.me/¨; CustomTabsIntent.Builder builder = new CustomTabsIntent.Builder(); CustomTabsIntent customTabsIntent = builder.build(); customTabsIntent.launchUrl(this, Uri.parse(url)); Question is that I want to add Intent.EXTRA_REFERRER to this. below is the para copied from their blog in their own

OidcClient2 - Closing IBrowser while waiting for LoginAsync

混江龙づ霸主 提交于 2020-06-27 15:55:07
问题 Currently I am developing a Xamarin App which is using IdentityModel.OidcClient to authenticate against my server, and it is being done using the automatic mode presented on the documentation (https://github.com/IdentityModel/IdentityModel.OidcClient2). Everything is working just fine as var result = await client.LoginAsync(); is returning the LoginResult with the AccessToken, etc. What I am trying to figure out is how the backbutton, the recent apps button (both on android) and the close

Chrome Custom Tabs change the default close button not working

China☆狼群 提交于 2020-06-13 18:39:08
问题 I am trying to change the default close button on the actionbar of the custom chrome tabs. I have tried to set using setCloseButtonIcon() However, the default close button still shows. I want to change the close to an arrow. My code below: public void openHomePage() { final CustomTabsIntent.Builder builder = new CustomTabsIntent.Builder(); builder.setToolbarColor(ContextCompat.getColor(getActivity(), R.color.primary)); final Bitmap backButton = BitmapFactory.decodeResource(getResources(), R

POST data via CustomTab or Chrome

坚强是说给别人听的谎言 提交于 2020-05-15 05:32:06
问题 I want send POST HTTP request via CustomTab or Chrome then show page finally. I many research but no way for it. is there a way? can send POST request via Volley then show response in browser finally? 回答1: I wrote a workaround for that. Careful, is a dirty one ;) Steps: you need to create an html file with a form inside it add input fields to it corresponding to the values you need to pass to your url add this file to your asset folder on android code: read the content of the file save the

How to hide the URL Of Custom Tab?

一笑奈何 提交于 2020-01-15 03:13:13
问题 I am using a custom tab in android. I have gone through many of the google search to hide the URL of custom tab but everywhere is showing that it is not possible to hide the URL.I just want to know that is there any way from which i can hide the url in custom tab. 回答1: You could try this ugly solution which can do the trick while you don't get a better solution: 1) create an html document with this contents: <frameset rows="100%"> <frameset cols="100%"> <frame src="http://192.169.218.96:7777"

Android Chrome Custom Tabs add Copy Link to options menu

十年热恋 提交于 2020-01-11 09:03:10
问题 How to add 'Copy link' option to Chrome Custom Tabs options menu in Android. Adding custom menu items in CustomTabs is like this. CustomTabsIntent.Builder customTabsIntent = new CustomTabsIntent.Builder(); String menuItemTitle = App.s(R.string.share); PendingIntent menuItemPendingIntent = createPendingIntentShare(url); customTabsIntent.addMenuItem(menuItemTitle, menuItemPendingIntent); I want to add Copy Link option just like Twitter do in his app browser. I am not sure how I can copy link to