@@ -93,11 +93,7 @@ public int getCount() {
93
93
return dbNotes .size () + 1 ;
94
94
}
95
95
96
- private Intent getCreateNoteIntent (Account localAccount ) {
97
- final Bundle bundle = new Bundle ();
98
- bundle .putSerializable (PARAM_CATEGORY , data .getMode () == MODE_DISPLAY_STARRED ? new NavigationCategory (ENavigationCategoryType .FAVORITES ) : new NavigationCategory (localAccount .getId (), data .getCategory ()));
99
- bundle .putLong (EditNoteActivity .PARAM_ACCOUNT_ID , data .getAccountId ());
100
-
96
+ private Intent getEditNoteIntent (Bundle bundle ) {
101
97
final Intent intent = new Intent (context , EditNoteActivity .class );
102
98
intent .setPackage (context .getPackageName ());
103
99
intent .putExtras (bundle );
@@ -106,16 +102,20 @@ private Intent getCreateNoteIntent(Account localAccount ) {
106
102
return intent ;
107
103
}
108
104
105
+ private Intent getCreateNoteIntent (Account localAccount ) {
106
+ final Bundle bundle = new Bundle ();
107
+ bundle .putSerializable (PARAM_CATEGORY , data .getMode () == MODE_DISPLAY_STARRED ? new NavigationCategory (ENavigationCategoryType .FAVORITES ) : new NavigationCategory (localAccount .getId (), data .getCategory ()));
108
+ bundle .putLong (EditNoteActivity .PARAM_ACCOUNT_ID , data .getAccountId ());
109
+
110
+ return getEditNoteIntent (bundle );
111
+ }
112
+
109
113
private Intent getOpenNoteIntent (Note note ) {
110
114
final Bundle bundle = new Bundle ();
111
115
bundle .putLong (EditNoteActivity .PARAM_NOTE_ID , note .getId ());
112
116
bundle .putLong (EditNoteActivity .PARAM_ACCOUNT_ID , note .getAccountId ());
113
117
114
- final Intent intent = new Intent (context , EditNoteActivity .class );
115
- intent .putExtras (bundle );
116
- intent .setData (Uri .parse (intent .toUri (Intent .URI_INTENT_SCHEME )));
117
-
118
- return intent ;
118
+ return getEditNoteIntent (bundle );
119
119
}
120
120
121
121
@ Override
0 commit comments