File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
activitytaskview/src/main/java/cc/rome753/activitytask Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change 66import android .os .Bundle ;
77import android .provider .Settings ;
88import android .view .View ;
9+ import android .widget .NumberPicker ;
910
1011import androidx .appcompat .app .AppCompatActivity ;
1112import androidx .databinding .DataBindingUtil ;
@@ -34,6 +35,7 @@ protected void onCreate(Bundle savedInstanceState) {
3435 System .exit (0 );
3536 });
3637
38+ binding .np .setDescendantFocusability (NumberPicker .FOCUS_BLOCK_DESCENDANTS );
3739 binding .np .setMaxValue (intervals .length - 1 );
3840 binding .np .setValue (3 );
3941 binding .np .setDisplayedValues (intervals );
Original file line number Diff line number Diff line change @@ -96,8 +96,8 @@ private void doClick() {
9696 }
9797
9898 private void doLongClick () {
99- Intent intent = new Intent (getContext (), MainActivity .class );
100- getContext ().startActivity (intent );
99+ Intent intent = new Intent (getContext (). getApplicationContext () , MainActivity .class );
100+ getContext ().getApplicationContext (). startActivity (intent );
101101 }
102102
103103 private void updateLayout (WindowManager .LayoutParams params ){
You can’t perform that action at this time.
0 commit comments