Search in sources :

Example 1 with OnIDPChangeListener

use of com.android.launcher3.InvariantDeviceProfile.OnIDPChangeListener in project android_packages_apps_Launcher3 by crdroidandroid.

the class InvariantDeviceProfile method onConfigChanged.

private void onConfigChanged(Context context) {
    // Re-init grid
    String gridName = getCurrentGridName(context);
    initGrid(context, Utilities.getPrefs(context).getString(KEY_IDP_GRID_NAME, gridName));
    for (OnIDPChangeListener listener : mChangeListeners) {
        listener.onIdpChanged(this);
    }
}
Also used : Utilities.getPointString(com.android.launcher3.Utilities.getPointString)

Example 2 with OnIDPChangeListener

use of com.android.launcher3.InvariantDeviceProfile.OnIDPChangeListener in project Neo-Launcher by NeoApplications.

the class InvariantDeviceProfile method apply.

private void apply(Context context, int changeFlags) {
    // Create a new config monitor
    mConfigMonitor.unregister();
    mConfigMonitor = new ConfigMonitor(context, this::onConfigChanged);
    for (OnIDPChangeListener listener : mChangeListeners) {
        listener.onIdpChanged(changeFlags, this);
    }
}
Also used : ConfigMonitor(com.android.launcher3.util.ConfigMonitor)

Example 3 with OnIDPChangeListener

use of com.android.launcher3.InvariantDeviceProfile.OnIDPChangeListener in project android_packages_apps_Trebuchet by LineageOS.

the class InvariantDeviceProfile method apply.

private void apply(Context context, int changeFlags) {
    // Create a new config monitor
    mConfigMonitor.unregister();
    mConfigMonitor = new ConfigMonitor(context, this::onConfigChanged);
    for (OnIDPChangeListener listener : mChangeListeners) {
        listener.onIdpChanged(changeFlags, this);
    }
}
Also used : ConfigMonitor(com.android.launcher3.util.ConfigMonitor)

Aggregations

ConfigMonitor (com.android.launcher3.util.ConfigMonitor)2 Utilities.getPointString (com.android.launcher3.Utilities.getPointString)1