Class AdBaseDialog

java.lang.Object
android.app.Dialog
org.prebid.mobile.rendering.interstitial.AdBaseDialog
All Implemented Interfaces:
android.content.DialogInterface, android.view.KeyEvent.Callback, android.view.View.OnCreateContextMenuListener, android.view.Window.Callback
Direct Known Subclasses:
AdExpandedDialog, AdInterstitialDialog, InterstitialVideo, VideoDialog

public abstract class AdBaseDialog extends android.app.Dialog
  • Nested Class Summary

    Nested classes/interfaces inherited from interface android.content.DialogInterface

    android.content.DialogInterface.OnCancelListener, android.content.DialogInterface.OnClickListener, android.content.DialogInterface.OnDismissListener, android.content.DialogInterface.OnKeyListener, android.content.DialogInterface.OnMultiChoiceClickListener, android.content.DialogInterface.OnShowListener
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected android.widget.FrameLayout
     
    protected boolean
    Is used when deciding to handle orientation changes.
    protected android.view.View
     
     
    protected boolean
     
    protected int
     
     
    protected JsExecutor
     
    protected android.view.View
     
    protected android.view.View
     
    protected WebViewBase
     

    Fields inherited from interface android.content.DialogInterface

    BUTTON_NEGATIVE, BUTTON_NEUTRAL, BUTTON_POSITIVE, BUTTON1, BUTTON2, BUTTON3
  • Constructor Summary

    Constructors
    Constructor
    Description
    AdBaseDialog(android.content.Context context, InterstitialManager interstitialManager)
     
    AdBaseDialog(android.content.Context context, WebViewBase webViewBaseLocal, InterstitialManager interstitialManager)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
     
    protected void
     
    protected void
    addSoundView(boolean isMutedOnStart)
     
    void
     
    void
    changeCloseViewVisibility(int visibility)
    Changes closeView visibility.
    void
     
    protected android.view.View
    createSoundView(android.content.Context context)
     
    protected android.app.Activity
     
    android.view.View
     
    protected abstract void
    Is executed when the close button is clicked.
    protected abstract void
     
    void
     
    protected void
     
    protected void
     
    protected void
    lockOrientation(int screenOrientation)
     
    protected void
     
    void
    onWindowFocusChanged(boolean hasWindowFocus)
     
    protected void
     
    void
     
    void
    setDisplayView(android.view.View displayView)
     
    protected void
     

    Methods inherited from class android.app.Dialog

    addContentView, closeOptionsMenu, create, dismiss, dispatchGenericMotionEvent, dispatchKeyEvent, dispatchKeyShortcutEvent, dispatchPopulateAccessibilityEvent, dispatchTouchEvent, dispatchTrackballEvent, findViewById, getActionBar, getContext, getCurrentFocus, getLayoutInflater, getOnBackInvokedDispatcher, getOwnerActivity, getSearchEvent, getVolumeControlStream, getWindow, hide, invalidateOptionsMenu, isShowing, onActionModeFinished, onActionModeStarted, onAttachedToWindow, onBackPressed, onContentChanged, onContextItemSelected, onContextMenuClosed, onCreate, onCreateContextMenu, onCreateOptionsMenu, onCreatePanelMenu, onCreatePanelView, onDetachedFromWindow, onGenericMotionEvent, onKeyDown, onKeyLongPress, onKeyMultiple, onKeyShortcut, onKeyUp, onMenuItemSelected, onMenuOpened, onOptionsItemSelected, onOptionsMenuClosed, onPanelClosed, onPrepareOptionsMenu, onPreparePanel, onRestoreInstanceState, onSaveInstanceState, onSearchRequested, onSearchRequested, onStart, onStop, onTouchEvent, onTrackballEvent, onWindowAttributesChanged, onWindowStartingActionMode, onWindowStartingActionMode, openContextMenu, openOptionsMenu, registerForContextMenu, requestWindowFeature, requireViewById, setCancelable, setCanceledOnTouchOutside, setCancelMessage, setContentView, setContentView, setContentView, setDismissMessage, setFeatureDrawable, setFeatureDrawableAlpha, setFeatureDrawableResource, setFeatureDrawableUri, setOnCancelListener, setOnDismissListener, setOnKeyListener, setOnShowListener, setOwnerActivity, setTitle, setTitle, setVolumeControlStream, show, takeKeyEvents, unregisterForContextMenu

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface android.view.Window.Callback

    onPointerCaptureChanged, onProvideKeyboardShortcuts
  • Field Details

    • jsExecutor

      protected JsExecutor jsExecutor
    • interstitialManager

      protected InterstitialManager interstitialManager
    • webViewBase

      protected WebViewBase webViewBase
    • adViewContainer

      protected android.widget.FrameLayout adViewContainer
    • displayView

      protected android.view.View displayView
    • soundView

      protected android.view.View soundView
    • skipView

      protected android.view.View skipView
    • forceOrientation

      protected OrientationManager.ForcedOrientation forceOrientation
    • allowOrientationChange

      protected boolean allowOrientationChange
      Is used when deciding to handle orientation changes. Orientation changes allowed (true) by default.
    • hasExpandProperties

      protected boolean hasExpandProperties
    • initialOrientation

      protected int initialOrientation
  • Constructor Details

    • AdBaseDialog

      public AdBaseDialog(android.content.Context context, InterstitialManager interstitialManager)
    • AdBaseDialog

      public AdBaseDialog(android.content.Context context, WebViewBase webViewBaseLocal, InterstitialManager interstitialManager)
  • Method Details

    • setDialogListener

      public void setDialogListener(DialogEventListener listener)
    • onWindowFocusChanged

      public void onWindowFocusChanged(boolean hasWindowFocus)
      Specified by:
      onWindowFocusChanged in interface android.view.Window.Callback
      Overrides:
      onWindowFocusChanged in class android.app.Dialog
    • cancel

      public void cancel()
      Specified by:
      cancel in interface android.content.DialogInterface
      Overrides:
      cancel in class android.app.Dialog
    • getDisplayView

      public android.view.View getDisplayView()
    • setDisplayView

      public void setDisplayView(android.view.View displayView)
    • changeCloseViewVisibility

      public void changeCloseViewVisibility(int visibility)
      Changes closeView visibility. if closeView is not defined - visibility is remembered and applied when closeView is added to container
    • handleSetOrientationProperties

      public void handleSetOrientationProperties() throws AdException
      Throws:
      AdException
    • cleanup

      public void cleanup()
    • handleCloseClick

      protected abstract void handleCloseClick()
      Is executed when the close button is clicked. It is child job to handle the click
    • handleDialogShow

      protected abstract void handleDialogShow()
    • preInit

      protected void preInit()
    • init

      protected void init()
    • MraidContinue

      protected void MraidContinue()
    • lockOrientation

      protected void lockOrientation()
    • lockOrientation

      protected void lockOrientation(int screenOrientation)
    • unApplyOrientation

      protected void unApplyOrientation()
    • getActivity

      protected android.app.Activity getActivity()
    • addCloseView

      protected void addCloseView()
    • addSkipView

      protected void addSkipView()
    • addSoundView

      protected void addSoundView(boolean isMutedOnStart)
    • createSoundView

      protected android.view.View createSoundView(android.content.Context context)