Called when the activity is first created.
343719
@Override
	public void onCreate(final Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);

		final RelativeLayout rl = new RelativeLayout(this);

		this.mMapView = new MapView(this);
		this.mMapView.setTilesScaledToDpi(true);
		rl.addView(this.mMapView, new RelativeLayout.LayoutParams(LayoutParams.FILL_PARENT,
				LayoutParams.FILL_PARENT));

		mMapView.setBuiltInZoomControls(true);

		/* MiniMap */
		{
			MinimapOverlay miniMapOverlay = new MinimapOverlay(this,
					mMapView.getTileRequestCompleteHandler());
			this.mMapView.getOverlays().add(miniMapOverlay);
		}

		this.setContentView(rl);

		// Default location and zoom level
		IMapController mapController = mMapView.getController();
		mapController.setZoom(5);
		GeoPoint startPoint = new GeoPoint(50.936255, 6.957779);
		mapController.setCenter(startPoint);
	}
850856
final void rawLaunchIntent(Intent intent) {
    if (intent != null) {
      intent.addFlags(Intents.FLAG_NEW_DOC);
      activity.startActivity(intent);
    }
  }
628531
@Override
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(cn.leancloud.sample.R.layout.main);

    setupAVOSCloud(false);
    setupGroupAdapter();
  }
600611
@Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        italicFont = Typeface.createFromAsset(getActivity().getAssets(), "fonts/Roboto-Italic.ttf");
        regularFont = Typeface.createFromAsset(getActivity().getAssets(), "fonts/Roboto-Regular.ttf");
        boldItalicFont = Typeface.createFromAsset(getActivity().getAssets(), "fonts/Roboto-BoldItalic.ttf");
    }
1314695
@Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        // storing string resources into Array
        String[] pages = getResources().getStringArray(R.array.pages);

        // Binding resources Array to ListAdapter
        this.setListAdapter(new ArrayAdapter<String>(this, R.layout.list_item, R.id.label, pages));

        ListView lv = getListView();

        // listening to single list item on click
        lv.setOnItemClickListener(new OnItemClickListener() {
          public void onItemClick(AdapterView<?> parent, View view,
              int position, long id) {
              // selected item
              String product = ((TextView) view).getText().toString();

              // Launching new Activity on selecting single List Item
              Intent i = new Intent(getApplicationContext(), TestActivity.class);
              i.putExtra("product", product.concat(" page"));

              if (product.equals("WebView")) {
                  i = new Intent(getApplicationContext(), WebviewActivity.class);
              } else if (product.equals("Notification")) {
                  // generate a notification instead of starting a new activity
                  NotificationManager notificationManager = (NotificationManager)
                          getSystemService(NOTIFICATION_SERVICE);

                  PendingIntent pIntent = PendingIntent.getActivity(getApplicationContext(), 0, i, 0);

                  Notification n  = new Notification.Builder(getApplicationContext())
                          .setContentTitle(getString(R.string.notification_title))
                          .setContentText(getString(R.string.notification_text))
                          .setContentIntent(pIntent)
                          .setSmallIcon(android.R.drawable.ic_dialog_alert)
                          .setAutoCancel(true).build();

                  notificationManager.notify(0, n);
                  System.out.println("HelloWorld:: Sending notification");

                  return;
              }

              // sending data to new activity
              startActivity(i);
          }
        });
    }
269107
@Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_eula);
        initUI();
        parseExtras(savedInstanceState);
    }
362783
@Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        mConfigResId = getArguments().getInt(EXTRA_CONFIG);

        //setStyle(DialogFragment.STYLE_NO_TITLE, R.style.Theme_AppCompat_Light);
    }
859420
private void createStackAndPushStartActivity(){
		activityStack = new Stack<WeakReference<Activity>>();
		if (activity != null && config.trackActivities){
			WeakReference<Activity> weakReference = new WeakReference<Activity>(activity);
			activity = null;
			activityStack.push(weakReference);
		}
	}
339944
@Override
    public void onViewCreated(View view, Bundle savedInstanceState) {
        super.onViewCreated(view, savedInstanceState);
        ensureContent();
    }
1122292
@NonNull @MainThread static ActivityScopedCache getOrCreateActivityScopedCache(
      @NonNull Activity activity) {
    if (activity == null) {
      throw new NullPointerException("Activity is null");
    }

    String activityId = activityIdMap.get(activity);
    if (activityId == null) {
      // Activity not registered yet
      activityId = UUID.randomUUID().toString();
      activityIdMap.put(activity, activityId);

      if (activityIdMap.size() == 1) {
        // Added the an Activity for the first time so register Activity LifecycleListener
        activity.getApplication().registerActivityLifecycleCallbacks(activityLifecycleCallbacks);
        if (DEBUG) {
          Log.d(DEBUG_TAG, "Registering ActivityLifecycleCallbacks");
        }
      }
    }

    ActivityScopedCache activityScopedCache = activityScopedCacheMap.get(activityId);
    if (activityScopedCache == null) {
      activityScopedCache = new ActivityScopedCache();
      activityScopedCacheMap.put(activityId, activityScopedCache);
    }

    return activityScopedCache;
  }
808582
@Override
    public void onCreate(Bundle savedInstanceState) {
		// Call superclass creator.
        super.onCreate(savedInstanceState);
        
		// Set layout.
        this.setContentView(R.layout.dialog_file_chooser);
		
		// Set the background color.
        LinearLayout layout = (LinearLayout) this.findViewById(R.id.rootLayout);
        layout.setBackgroundColor(getResources().getColor(R.color.daidalos_backgroud));

		// Initialize fields.
		this.useBackButton = false;
		
        // Create the core of the file chooser.
        this.core = new FileChooserCore(this);
        
        // Verify if the optional parameters has been defined.
        String folderPath = null;
        Bundle extras = this.getIntent().getExtras();
        if(extras != null) {
    		if(extras.containsKey(INPUT_START_FOLDER)) folderPath = extras.getString(INPUT_START_FOLDER);
            if(extras.containsKey(INPUT_REGEX_FILTER)) core.setFilter(extras.getString(INPUT_REGEX_FILTER));
            if(extras.containsKey(INPUT_SHOW_ONLY_SELECTABLE)) core.setShowOnlySelectable(extras.getBoolean(INPUT_SHOW_ONLY_SELECTABLE));
            if(extras.containsKey(INPUT_FOLDER_MODE)) core.setFolderMode(extras.getBoolean(INPUT_FOLDER_MODE));
            if(extras.containsKey(INPUT_CAN_CREATE_FILES)) core.setCanCreateFiles(extras.getBoolean(INPUT_CAN_CREATE_FILES));
            if(extras.containsKey(INPUT_LABELS)) core.setLabels((FileChooserLabels) extras.get(INPUT_LABELS));
            if(extras.containsKey(INPUT_SHOW_CONFIRMATION_ON_CREATE)) core.setShowConfirmationOnCreate(extras.getBoolean(INPUT_SHOW_CONFIRMATION_ON_CREATE));
            if(extras.containsKey(INPUT_SHOW_CONFIRMATION_ON_SELECT)) core.setShowConfirmationOnSelect(extras.getBoolean(INPUT_SHOW_CONFIRMATION_ON_SELECT));
            if(extras.containsKey(INPUT_SHOW_FULL_PATH_IN_TITLE)) core.setShowFullPathInTitle(extras.getBoolean(INPUT_SHOW_FULL_PATH_IN_TITLE));
            if(extras.containsKey(INPUT_USE_BACK_BUTTON_TO_NAVIGATE)) this.useBackButton = extras.getBoolean(INPUT_USE_BACK_BUTTON_TO_NAVIGATE);
        }

        // Load the files of a folder.
        core.loadFolder(folderPath);
        this.startFolder = this.core.getCurrentFolder();
        
        // Add a listener for when a file is selected.
        core.addListener(new FileChooserCore.OnFileSelectedListener() {
			public void onFileSelected(File folder, String name) {
				// Pass the data through an intent.
				Intent intent = new Intent();
				Bundle bundle = new Bundle();
				bundle.putSerializable(OUTPUT_FILE_OBJECT, folder);
				bundle.putString(OUTPUT_NEW_FILE_NAME, name);
				intent.putExtras(bundle);
				
                setResult(RESULT_OK, intent);
                finish();				
			}
			public void onFileSelected(File file) {
				// Pass the data through an intent.
				Intent intent = new Intent();
				Bundle bundle = new Bundle();
				bundle.putSerializable(OUTPUT_FILE_OBJECT, file);
				intent.putExtras(bundle);
				
                setResult(RESULT_OK, intent);
                finish();	
			}
		});
    }
706448
@Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        createSharedPreferences();
        createMapViews();
        createTileCaches();
        checkPermissionsAndCreateLayersAndControls();
    }
422325
function startActivity(activityMessage) {
  var activityId = createActivity(activityMessage);

  markActivity(activityId);

  var activity = getActivity(activityId);
  writeActivity(activityEvents.start, activity);

  return activityId;
}
1031428
@Override
	public void onSimonCreated(Simon simon) {
		if (simon instanceof Stopwatch) {
			Stopwatch stopwatch = (Stopwatch) simon;
			getOrCreateBucketsValues(stopwatch);
		}
	}
701668
void onActivityReady(Activity activity) {
    this.activity = activity;

    PermissionStates permissionStates = null;
    synchronized (pendingPermissionsMutex) {
      if (activity != null) {
        permissionStates = getPermissionStates(pendingPermissions);
      }
    }

    if (permissionStates != null) {
      handleDeniedPermissions(permissionStates.getDeniedPermissions());
      updatePermissionsAsDenied(permissionStates.getImpossibleToGrantPermissions());
      updatePermissionsAsGranted(permissionStates.getGrantedPermissions());
    }
  }
113200
@Override
    protected void onCreate(Bundle savedInstanceState) {
        final RoboInjector injector = RoboGuice.getInjector(this);
        eventManager = injector.getInstance(EventManager.class);
        preferenceListener = injector.getInstance(PreferenceListener.class);
        injector.injectMembersWithoutViews(this);
        super.onCreate(savedInstanceState);
        eventManager.fire(new OnCreateEvent(savedInstanceState));
    }
758971
static void onActivityCreated(Activity activity) {
        // make sure we have at least the default instance created here.
        if (instances == null) {
            CleverTapAPI.createInstanceIfAvailable(activity, null);
        }

        if (instances == null) {
            Logger.v("Instances is null in onActivityCreated!");
            return;
        }

        boolean alreadyProcessedByCleverTap = false;
        Bundle notification = null;
        Uri deepLink = null;
        String _accountId = null;

        // check for launch deep link
        try {
            Intent intent = activity.getIntent();
            deepLink = intent.getData();
            if (deepLink != null) {
                Bundle queryArgs = UriHelper.getAllKeyValuePairs(deepLink.toString(), true);
                _accountId = queryArgs.getString(Constants.WZRK_ACCT_ID_KEY);
            }
        } catch (Throwable t) {
            // Ignore
        }

        // check for launch via notification click
        try {
            notification = activity.getIntent().getExtras();
            if (notification != null && !notification.isEmpty()) {
                try {
                    alreadyProcessedByCleverTap = (notification.containsKey(Constants.WZRK_FROM_KEY) && Constants.WZRK_FROM.equals(notification.get(Constants.WZRK_FROM_KEY)));
                    if (alreadyProcessedByCleverTap){
                        Logger.v("ActivityLifecycleCallback: Notification Clicked already processed for "+ notification.toString() +", dropping duplicate.");
                    }
                    if (notification.containsKey(Constants.WZRK_ACCT_ID_KEY)) {
                        _accountId = (String) notification.get(Constants.WZRK_ACCT_ID_KEY);
                    }
                } catch (Throwable t) {
                    // no-op
                }
            }
        } catch (Throwable t) {
            // Ignore
        }

        if (alreadyProcessedByCleverTap && deepLink == null) return;

        for (String accountId: CleverTapAPI.instances.keySet()) {
            CleverTapAPI instance = CleverTapAPI.instances.get(accountId);

            boolean shouldProcess = false;
            if (instance != null) {
                shouldProcess = (_accountId == null && instance.config.isDefaultInstance()) || instance.getAccountId().equals(_accountId);
            }

            if (shouldProcess) {
                if (notification != null && !notification.isEmpty() && notification.containsKey(Constants.NOTIFICATION_TAG)) {
                    instance.pushNotificationClickedEvent(notification);
                }

                if (deepLink != null) {
                    try {
                        instance.pushDeepLink(deepLink);
                    } catch (Throwable t) {
                        // no-op
                    }
                }
                break;
            }
        }
    }