Android frameworks 开发总结之九(Settings)
1.移除Settings首頁所有suggestion項
XXX設備按照客人要求需要移除Settings中所有的suggestion項,比喻:Finish setting up your device,Customize your device等。
修改packages/apps/SettingsIntelligence/src/com/android/settings/intelligence/suggestions/SuggestionParser.java 文件中的getSuggestions方法:
public List<Suggestion> getSuggestions() {
final SuggestionListBuilder suggestionBuilder = new SuggestionListBuilder();
for (SuggestionCategory category : CATEGORIES) {
if (category.isExclusive() && !isExclusiveCategoryExpired(category)) {
// If suggestions from an exclusive category are present, parsing is stopped
// and only suggestions from that category are displayed. Note that subsequent
// exclusive categories are also ignored.
// Read suggestion and force ignoreSuggestionDismissRule to be