protected override void UpdateAttributes(XmlDocument document) { for (int i = 0; i < intentFilterList.Count; i++) { ManifestIntentFilter intentFIlter = intentFilterList[i]; if (intentFIlter.ElementEditStatus == EditStatus.REMOVED) { intentFilterList.RemoveAt(i); i--; } intentFIlter.ApplyChanges(document); } for (int i = 0; i < metaDataList.Count; i++) { ManifestMetaData metaData = metaDataList[i]; if (metaData.ElementEditStatus == EditStatus.REMOVED) { metaDataList.RemoveAt(i); i--; } metaData.ApplyChanges(document); } CreateAndroidAttribute(document, "name", name); UpdateOptionalAttribute(document, "enabled", !enabled, "false"); UpdateOptionalAttribute(document, "exported", !exported, "false"); UpdateOptionalAttribute(document, "icon", !icon.Equals(""), icon); UpdateOptionalAttribute(document, "label", !label.Equals(""), label); UpdateOptionalAttribute(document, "permission", !permission.Equals(""), permission); UpdateOptionalAttribute(document, "process", !process.Equals(""), process); }
protected override void UpdateAttributes(XmlDocument document) { if (node.OwnerDocument != document) { CopyNode(document); } for (int i = 0; i < intentFilterList.Count; i++) { ManifestIntentFilter intentFIlter = intentFilterList[i]; if (intentFIlter.ElementEditStatus == EditStatus.REMOVED) { intentFilterList.RemoveAt(i); i--; } intentFIlter.ApplyChanges(document); } for (int i = 0; i < metaDataList.Count; i++) { ManifestMetaData metaData = metaDataList[i]; if (metaData.ElementEditStatus == EditStatus.REMOVED) { metaDataList.RemoveAt(i); i--; } metaData.ApplyChanges(document); } CreateAndroidAttribute(document, "name", name); UpdateOptionalAttribute(document, "allowTaskReparenting", allowTaskReparenting, "true"); UpdateOptionalAttribute(document, "alwaysRetainTaskState", alwaysRetainTaskState, "true"); UpdateOptionalAttribute(document, "clearTaskOnLaunch", clearTaskOnLaunch, "true"); UpdateOptionalAttribute(document, "configChanges", configChanges != 0, ConfigChangesToString()); UpdateOptionalAttribute(document, "enabled", !enabled, "false"); UpdateOptionalAttribute(document, "excludeFromRecents", excludeFromRecents, "true"); UpdateOptionalAttribute(document, "exported", !exported, "false"); UpdateOptionalAttribute(document, "finishOnTaskLaunch", finishOnTaskLaunch, "true"); UpdateOptionalAttribute(document, "hardwareAccelerated", hardwareAccelerated, "true"); UpdateOptionalAttribute(document, "icon", !icon.Equals(""), icon); UpdateOptionalAttribute(document, "label", !label.Equals(""), label); UpdateOptionalAttribute(document, "launchMode", launchMode != launchModeArray[0], launchMode); UpdateOptionalAttribute(document, "multiprocess", multiprocess, "true"); UpdateOptionalAttribute(document, "noHistory", noHistory, "true"); UpdateOptionalAttribute(document, "permission", !permission.Equals(""), permission); UpdateOptionalAttribute(document, "process", !process.Equals(""), process); UpdateOptionalAttribute(document, "screenOrientation", screenOrientation != screenOrientationArray [0], screenOrientation); UpdateOptionalAttribute(document, "stateNotNeeded", stateNotNeeded, "true"); UpdateOptionalAttribute(document, "taskAffinity", !taskAffinity.Equals(""), taskAffinity); UpdateOptionalAttribute(document, "theme", !theme.Equals(""), theme); UpdateOptionalAttribute(document, "uiOptions", !uiOptions.Equals(uiOptionsArray[0]), uiOptions); UpdateOptionalAttribute(document, "windowSoftInputMode", windowSoftInputMode != 0, WindowSoftInputModeToString()); }
protected override void UpdateAttributes(XmlDocument document) { for (int i = 0; i < metaDataList.Count; i++) { ManifestMetaData metaData = metaDataList[i]; if (metaData.ElementEditStatus == EditStatus.REMOVED) { metaDataList.RemoveAt(i); i--; } metaData.ApplyChanges(document); } for (int i = 0; i < grantUriPermissionList.Count; i++) { ManifestGrantUriPermission uriPermission = grantUriPermissionList[i]; if (uriPermission.ElementEditStatus == EditStatus.REMOVED) { grantUriPermissionList.RemoveAt(i); i--; } uriPermission.ApplyChanges(document); } for (int i = 0; i < pathPermissionList.Count; i++) { ManifestPathPermission pathPermission = pathPermissionList[i]; if (pathPermission.ElementEditStatus == EditStatus.REMOVED) { pathPermissionList.RemoveAt(i); i--; } pathPermission.ApplyChanges(document); } CreateAndroidAttribute(document, "name", name); CreateAndroidAttribute(document, "authorities", AuthoritiesToString()); UpdateOptionalAttribute(document, "enabled", !enabled, "false"); UpdateOptionalAttribute(document, "exported", !exported, "false"); UpdateOptionalAttribute(document, "grantUriPermissions", grantUriPermissions, "true"); UpdateOptionalAttribute(document, "icon", !icon.Equals(""), icon); UpdateOptionalAttribute(document, "initOrder", initOrder != 0, "" + initOrder); UpdateOptionalAttribute(document, "label", !label.Equals(""), label); UpdateOptionalAttribute(document, "multiprocess", multiProcess, "true"); UpdateOptionalAttribute(document, "permission", !permission.Equals(""), permission); UpdateOptionalAttribute(document, "process", !process.Equals(""), process); UpdateOptionalAttribute(document, "readPermission", !readPermission.Equals(""), readPermission); UpdateOptionalAttribute(document, "syncable", syncable, "true"); UpdateOptionalAttribute(document, "writePermission", !writePermission.Equals(""), writePermission); }