本文整理匯總了Java中org.chromium.chrome.browser.tabmodel.TabReparentingParams.finalizeTabReparenting方法的典型用法代碼示例。如果您正苦於以下問題:Java TabReparentingParams.finalizeTabReparenting方法的具體用法?Java TabReparentingParams.finalizeTabReparenting怎麽用?Java TabReparentingParams.finalizeTabReparenting使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類org.chromium.chrome.browser.tabmodel.TabReparentingParams
的用法示例。
在下文中一共展示了TabReparentingParams.finalizeTabReparenting方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: attachAndFinishReparenting
import org.chromium.chrome.browser.tabmodel.TabReparentingParams; //導入方法依賴的package包/類
/**
* Finishes the tab reparenting process. Attaches the tab to the new activity, and updates the
* tab and related objects to reference the new activity. This updates many delegates inside the
* tab and {@link ContentViewCore} both on java and native sides.
*
* @param activity The new activity this tab should be associated with.
* @param tabDelegateFactory The new delegate factory this tab should be using.
* @Param reparentingParams The TabReparentingParams associated with this reparenting process.
*/
public void attachAndFinishReparenting(ChromeActivity activity,
TabDelegateFactory tabDelegateFactory, TabReparentingParams reparentingParams) {
// TODO(yusufo): Share these calls with the construction related calls.
// crbug.com/590281
updateWindowAndroid(activity.getWindowAndroid());
// Update for the controllers that need the Compositor from the new Activity.
attachTabContentManager(activity.getTabContentManager());
mFullscreenManager = activity.getFullscreenManager();
activity.getCompositorViewHolder().prepareForTabReparenting();
// Update the delegate factory, then recreate and propagate all delegates.
mDelegateFactory = tabDelegateFactory;
mWebContentsDelegate = mDelegateFactory.createWebContentsDelegate(this);
nativeUpdateDelegates(mNativeTabAndroid,
mWebContentsDelegate, mDelegateFactory.createContextMenuPopulator(this));
mBrowserControlsVisibilityDelegate =
mDelegateFactory.createBrowserControlsVisibilityDelegate(this);
setInterceptNavigationDelegate(mDelegateFactory.createInterceptNavigationDelegate(this));
getAppBannerManager().setIsEnabledForTab(mDelegateFactory.canShowAppBanners(this));
reparentingParams.finalizeTabReparenting();
mIsDetachedForReparenting = false;
// Reload the NativePage (if any), since the old NativePage has a reference to the old
// activity.
maybeShowNativePage(getUrl(), true);
mIsTabStateDirty = true;
for (TabObserver observer : mObservers) {
observer.onReparentingFinished(this);
}
}
示例2: attachAndFinishReparenting
import org.chromium.chrome.browser.tabmodel.TabReparentingParams; //導入方法依賴的package包/類
/**
* Finishes the tab reparenting process. Attaches the tab to the new activity, and updates the
* tab and related objects to reference the new activity. This updates many delegates inside the
* tab and {@link ContentViewCore} both on java and native sides.
*
* @param activity The new activity this tab should be associated with.
* @param tabDelegateFactory The new delegate factory this tab should be using.
* @Param reparentingParams The TabReparentingParams associated with this reparenting process.
*/
public void attachAndFinishReparenting(ChromeActivity activity,
TabDelegateFactory tabDelegateFactory, TabReparentingParams reparentingParams) {
// TODO(yusufo): Share these calls with the construction related calls.
// crbug.com/590281
updateWindowAndroid(activity.getWindowAndroid());
// Update for the controllers that need the Compositor from the new Activity.
attachTabContentManager(activity.getTabContentManager());
mFullscreenManager = activity.getFullscreenManager();
activity.getCompositorViewHolder().prepareForTabReparenting();
// Update the delegate factory, then recreate and propagate all delegates.
mDelegateFactory = tabDelegateFactory;
mWebContentsDelegate = mDelegateFactory.createWebContentsDelegate(this);
nativeUpdateDelegates(mNativeTabAndroid,
mWebContentsDelegate, mDelegateFactory.createContextMenuPopulator(this));
mBrowserControlsVisibilityDelegate =
mDelegateFactory.createBrowserControlsVisibilityDelegate(this);
setInterceptNavigationDelegate(mDelegateFactory.createInterceptNavigationDelegate(this));
getAppBannerManager().setIsEnabledForTab(mDelegateFactory.canShowAppBanners(this));
reparentingParams.finalizeTabReparenting();
mIsDetached = false;
nativeAttachDetachedTab(mNativeTabAndroid);
// Reload the NativePage (if any), since the old NativePage has a reference to the old
// activity.
maybeShowNativePage(getUrl(), true);
mIsTabStateDirty = true;
for (TabObserver observer : mObservers) {
observer.onReparentingFinished(this);
}
}