Beispiel #1
0
 public int onStartCommand(Intent paramIntent, int paramInt1, int paramInt2)
 {
   this.mStartId = paramInt2;
   this.mStartupCount = (1 + this.mStartupCount);
   Runnable local1 = new Runnable()
   {
     private int mLoaded;
     
     public final void run()
     {
       this.mLoaded = (1 + this.mLoaded);
       if (this.mLoaded == 2)
       {
         ExternalReferrer.ExternalReferrerService.access$110(ExternalReferrer.ExternalReferrerService.this);
         ExternalReferrer.access$200(this.val$packageName, this.val$isAdded);
         if (ExternalReferrer.ExternalReferrerService.this.mStartupCount <= 0) {
           ExternalReferrer.ExternalReferrerService.this.stopSelf(ExternalReferrer.ExternalReferrerService.this.mStartId);
         }
       }
     }
   };
   FinskyApp.get().mLibraries.load(local1);
   FinskyApp.get().mAppStates.load(local1);
   return 3;
 }
 private void showGenericError(String finskyLogString, String logString) {
   showError(
       finskyLogString,
       logString,
       FinskyApp.get()
           .getString(R.string.add_carrier_billing_error, new Object[] {this.mParams.getName()}));
 }
 protected int getCardLayoutResId() {
   if ((this.mContext.getResources().getBoolean(2131427339))
       && (FinskyApp.get().getExperiments().isEnabled(12604267L))) {}
   for (int i = 1; i != 0; i = 0) {
     return 2130968939;
   }
   return 2130968954;
 }
 public SimpleCardClusterModule() {
   FinskyExperiments localFinskyExperiments = FinskyApp.get().getExperiments();
   if ((localFinskyExperiments.isH20StoreEnabled())
       && (!localFinskyExperiments.isEnabled(12604101L))) {}
   for (boolean bool = true; ; bool = false) {
     this.mShouldUseScrollableClusters = bool;
     return;
   }
 }
 private static void logNotificationImpression(int paramInt, Document paramDocument)
 {
   if (paramDocument != null) {}
   for (byte[] arrayOfByte = paramDocument.mDocument.serverLogsCookie;; arrayOfByte = null)
   {
     GenericUiElementNode localGenericUiElementNode = new GenericUiElementNode(paramInt, arrayOfByte, null, null);
     FinskyApp.get().getEventLogger().logPathImpression(0L, localGenericUiElementNode);
     return;
   }
 }
 boolean initParams() {
   if (this.mParams == null || this.mProvisioning == null) {
     FinskyLog.d(
         "Cannot run this BillingFlow since params or provisioning is null.", new Object[0]);
     fail(FinskyApp.get().getString(R.string.generic_purchase_prepare_error));
     return false;
   }
   setAddressAvailability();
   return true;
 }
Beispiel #7
0
 private static void logExternalReferrer(int paramInt1, String paramString1, int paramInt2, String paramString2)
 {
   BackgroundEventBuilder localBackgroundEventBuilder = new BackgroundEventBuilder(paramInt1).setDocument(paramString1).setReason(paramString2);
   if (paramInt2 >= 0)
   {
     PlayStore.AppData localAppData = new PlayStore.AppData();
     localAppData.version = paramInt2;
     localAppData.hasVersion = true;
     localBackgroundEventBuilder.setAppData(localAppData);
   }
   FinskyApp.get().getEventLogger().sendBackgroundEventToSinks(localBackgroundEventBuilder.event);
 }
 public final void onError(Download paramDownload, int paramInt)
 {
   Object[] arrayOfObject = new Object[2];
   arrayOfObject[0] = paramDownload;
   arrayOfObject[1] = Integer.valueOf(paramInt);
   FinskyLog.d("%s: onError %d.", arrayOfObject);
   if ((paramInt == 403) || (paramInt == 401)) {
     FinskyApp.get().getVendingApi().mApiContext.mReauthenticate = true;
   }
   remove(paramDownload);
   removeFromDownloadManager(paramDownload);
 }
 CreateCarrierBillingFlow(
     BillingFlowContext billingFlowContext,
     BillingFlowListener listener,
     CarrierBillingStorage storage,
     DfeApi dfeApi) {
   super(billingFlowContext, listener, null);
   this.mState = State.INIT;
   this.mAddressAvailable = AddressAvailable.NO_ADDRESS;
   this.mAddResult = null;
   this.mAddressMode = AddressMode.FULL_ADDRESS;
   this.mContext = billingFlowContext;
   this.mStorage = storage;
   this.mDfeApi = dfeApi;
   this.mParams = this.mStorage.getParams();
   this.mProvisioning = this.mStorage.getProvisioning();
   if (((Boolean) G.enableDcbReducedBillingAddress.get()).booleanValue()) {
     List<Country> countries = BillingLocator.getBillingCountries();
     if (countries != null) {
       Country carrierBillingCountry =
           BillingUtils.findCountry(
               BillingUtils.getDefaultCountry(FinskyApp.get(), null), countries);
       if (carrierBillingCountry != null) {
         this.mAddressMode =
             carrierBillingCountry.allowsReducedBillingAddress
                 ? AddressMode.REDUCED_ADDRESS
                 : AddressMode.FULL_ADDRESS;
       }
     }
   }
   if (this.mDfeApi != null) {
     this.mAccountName = this.mDfeApi.getAccountName();
   }
   if (this.mParams == null || this.mParams.getName() == null) {
     FinskyLog.e("No carrier name available in params.", new Object[0]);
   } else {
     this.mTitle =
         FinskyApp.get()
             .getString(R.string.dcb_setup_title, new Object[] {this.mParams.getName()});
   }
 }
Beispiel #10
0
 public static void saveExternalReferrer(final String paramString, Common.Docid paramDocid)
 {
   if ((paramDocid.backend != 3) || (paramDocid.type != 1)) {
     return;
   }
   final String str = paramDocid.backendDocid;
   AppStates localAppStates = FinskyApp.get().mAppStates;
   Runnable local1 = new Runnable()
   {
     public final void run()
     {
       AppStates.AppState localAppState = this.val$appStates.getApp(str);
       WriteThroughInstallerDataStore localWriteThroughInstallerDataStore = this.val$appStates.mStateStore;
       int i = FinskyApp.get().mInstaller.getState(str);
       String str = ExternalReferrer.saveReferrer(paramString, str, localAppState, i, localWriteThroughInstallerDataStore);
       if (str == null)
       {
         if (TextUtils.isEmpty(paramString))
         {
           Object[] arrayOfObject3 = new Object[1];
           arrayOfObject3[0] = str;
           FinskyLog.d("Capture referrer for %s (empty)", arrayOfObject3);
         }
         for (;;)
         {
           ExternalReferrer.logExternalReferrer(515, str, -1, null);
           return;
           Object[] arrayOfObject2 = new Object[1];
           arrayOfObject2[0] = str;
           FinskyLog.d("Capture referrer for %s", arrayOfObject2);
         }
       }
       Object[] arrayOfObject1 = new Object[2];
       arrayOfObject1[0] = str;
       arrayOfObject1[1] = str;
       FinskyLog.d("Dropped referrer for %s because %s", arrayOfObject1);
       int j = -1;
       if ((localAppState != null) && (localAppState.packageManagerState != null)) {
         j = localAppState.packageManagerState.installedVersion;
       }
       ExternalReferrer.logExternalReferrer(516, str, j, str);
     }
   };
   if ((Looper.myLooper() == Looper.getMainLooper()) && (localAppStates.mStateStore.isLoaded()))
   {
     local1.run();
     return;
   }
   localAppStates.load(local1);
 }
 private void showStorageFullAlertOrNotification$fb5dc8d(String paramString1, String paramString2, String paramString3, String paramString4, boolean paramBoolean)
 {
   if ((this.mListener != null) && (!this.mListener.shouldShowAppNotification$14e1ec69(paramString1)))
   {
     if (FinskyApp.get().getExperiments().isEnabled(12603367L))
     {
       this.mListener.showAppAlert(paramString1, paramString3, paramString4, 3);
       return;
     }
     if (paramBoolean) {}
     for (int i = 47;; i = 48)
     {
       ErrorDialog.Builder localBuilder = (ErrorDialog.Builder)((ErrorDialog.Builder)((ErrorDialog.Builder)((ErrorDialog.Builder)((ErrorDialog.Builder)((ErrorDialog.Builder)new ErrorDialog.Builder().setTitle(paramString3)).setMessageHtml(paramString4)).setPositiveId(2131362841)).setNegativeId(2131361915)).setCallback(null, i, null)).setEventLog(324, null, 2904, 2903, null);
       this.mListener.showAppAlert(paramString1, localBuilder);
       return;
     }
   }
   showAppNotificationOnly$1f519fb9(paramString1, paramString2, paramString3, paramString4, -1, "err");
 }
 public void bind(
     DfeApi dfeApi,
     DfeToc toc,
     String title,
     DfeList dfeList,
     BitmapLoader bitmapLoader,
     OnRefundActionListener onRefundActionListener,
     NavigationManager navManager,
     PlayStoreUiElementNode parentNode) {
   this.mTitleView.setText(title);
   this.mDfeApi = dfeApi;
   this.mToc = toc;
   this.mDfeList = dfeList;
   this.mNavigationManager = navManager;
   this.mParentNode = parentNode;
   this.mEventLogger = FinskyApp.get().getEventLogger(this.mDfeApi.getAccount());
   if (this.mDfeList == null || !this.mDfeList.isReady()) {
     this.mProgressIndicator.setVisibility(0);
     this.mOrderHistoryHolder.setVisibility(8);
     this.mMoreFooter.setVisibility(8);
     return;
   }
   this.mAdapter =
       new OrderHistoryAdapter(
           getContext(),
           this.mDfeList,
           bitmapLoader,
           this.mNavigationManager,
           onRefundActionListener,
           false,
           this);
   this.mProgressIndicator.setVisibility(8);
   this.mOrderHistoryHolder.setVisibility(0);
   Document containerDocument = this.mDfeList.getContainerDocument();
   if (containerDocument != null) {
     FinskyEventLog.setServerLogCookie(
         this.mUiElementProto, containerDocument.getServerLogsCookie());
   }
   getParentNode().childImpression(this);
   renderOrderHistoryList();
 }
 public void onReceive(Context context, Intent intent) {
   if (intent.getAction().equals("com.google.android.c2dm.intent.RECEIVE")) {
     setResultCode(-1);
     if (intent.getStringExtra("from").equals("google.com")) {
       String packageName = intent.getStringExtra("asset_package");
       String declinedReasonStr = intent.getStringExtra("decline_reason");
       int reason = -1;
       if (declinedReasonStr != null) {
         try {
           reason = Integer.valueOf(declinedReasonStr).intValue();
         } catch (NumberFormatException e) {
           FinskyLog.w("Non-numeric decline reason: %s", declinedReasonStr);
         }
       }
       FinskyLog.d(
           "Received PURCHASE_DECLINED tickle for %s reason=%d",
           packageName, Integer.valueOf(reason));
       FinskyApp.get()
           .getEventLogger()
           .logBackgroundEvent(200, packageName, String.valueOf(reason), 0, null, null);
     }
   }
 }
 private void showNetworkError(VolleyError error) {
   FinskyLog.w("Error received: %s", error);
   logError(error);
   showErrorDialog(ErrorStrings.get(FinskyApp.get(), error));
 }
Beispiel #15
0
 public static Intent createIntent(Account account, PurchaseParams params) {
   Intent intent = PurchaseActivity.createIntent(account, params, null, null);
   intent.setClass(FinskyApp.get(), IabV3Activity.class);
   return intent;
 }
Beispiel #16
0
 public final void onPackageFirstLaunch(String paramString)
 {
   FinskyLog.d("Package first launch for %s", new Object[] { paramString });
   ExternalReferrer.ExternalReferrerService.sendReferrer(FinskyApp.get(), paramString, false);
 }
Beispiel #17
0
 public final void onPackageAdded(String paramString)
 {
   ExternalReferrer.ExternalReferrerService.sendReferrer(FinskyApp.get(), paramString, true);
 }