File tree Expand file tree Collapse file tree 1 file changed +0
-9
lines changed Expand file tree Collapse file tree 1 file changed +0
-9
lines changed Original file line number Diff line number Diff line change @@ -29,28 +29,19 @@ fn build_ui(application: &Application) {
29
29
. margin_start (12 )
30
30
. margin_end (12 )
31
31
. build ();
32
- let button_decrease = Button :: builder ()
33
- . label (" Decrease" )
34
- . margin_top (12 )
35
- . margin_bottom (12 )
36
- . margin_start (12 )
37
- . margin_end (12 )
38
- . build ();
39
32
40
33
// A mutable integer
41
34
let mut number = 0 ;
42
35
43
36
// Connect callbacks
44
37
// When a button is clicked, `number` should be changed
45
38
button_increase . connect_clicked (| _ | number += 1 );
46
- button_decrease . connect_clicked (| _ | number -= 1 );
47
39
48
40
// Add buttons to `gtk_box`
49
41
let gtk_box = gtk :: Box :: builder ()
50
42
. orientation (Orientation :: Vertical )
51
43
. build ();
52
44
gtk_box . append (& button_increase );
53
- gtk_box . append (& button_decrease );
54
45
55
46
// Create a window
56
47
let window = ApplicationWindow :: builder ()
You can’t perform that action at this time.
0 commit comments