Changeset 25eec4ef in mainline for uspace/app
- Timestamp:
- 2013-04-19T18:38:18Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 6d717a4
- Parents:
- a1e2df13 (diff), 289cb7dd (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - Location:
- uspace/app
- Files:
-
- 1 added
- 4 deleted
- 52 edited
-
bdsh/cmds/modules/cat/cat.c (modified) (1 diff)
-
bdsh/cmds/modules/cp/cp.c (modified) (1 diff)
-
bdsh/cmds/modules/ls/ls.c (modified) (1 diff)
-
bdsh/cmds/modules/sleep/sleep.c (modified) (1 diff)
-
bdsh/compl.c (modified) (1 diff)
-
bdsh/input.c (modified) (1 diff)
-
bnchmark/bnchmark.c (modified) (1 diff)
-
edit/edit.c (modified) (11 diffs)
-
edit/sheet.h (modified) (1 diff)
-
ext2info/Makefile (deleted)
-
ext2info/ext2info.c (deleted)
-
init/init.c (modified) (2 diffs)
-
klog/Makefile (modified) (1 diff)
-
klog/klog.c (modified) (2 diffs)
-
mkbd/main.c (modified) (3 diffs)
-
mkexfat/exfat.h (modified) (1 diff)
-
mkexfat/mkexfat.c (modified) (1 diff)
-
msim/arch_helenos/input.c (modified) (1 diff)
-
netecho/netecho.c (modified) (5 diffs)
-
nettest2/nettest2.c (modified) (1 diff)
-
nettest3/nettest3.c (modified) (4 diffs)
-
nterm/conn.c (modified) (1 diff)
-
nterm/nterm.c (modified) (3 diffs)
-
ping/ping.c (modified) (3 diffs)
-
stats/stats.c (modified) (1 diff)
-
taskdump/symtab.c (modified) (1 diff)
-
taskdump/taskdump.c (modified) (1 diff)
-
tester/Makefile (modified) (2 diffs)
-
tester/ext2/ext2_1.c (deleted)
-
tester/ext2/ext2_1.def (deleted)
-
tester/float/softfloat1.c (modified) (9 diffs)
-
tester/ipc/starve.c (modified) (1 diff)
-
tester/mm/common.c (modified) (1 diff)
-
tester/mm/common.h (modified) (1 diff)
-
tester/mm/mapping1.c (modified) (1 diff)
-
tester/tester.c (modified) (1 diff)
-
tester/tester.h (modified) (2 diffs)
-
tetris/scores.c (modified) (3 diffs)
-
tetris/screen.c (modified) (4 diffs)
-
tetris/screen.h (modified) (1 diff)
-
top/screen.c (modified) (2 diffs)
-
trace/ipc_desc.c (modified) (1 diff)
-
trace/ipc_desc.h (modified) (1 diff)
-
trace/ipcp.c (modified) (2 diffs)
-
trace/syscalls.c (modified) (2 diffs)
-
trace/syscalls.h (modified) (2 diffs)
-
trace/trace.c (modified) (7 diffs)
-
usbinfo/desctree.c (modified) (1 diff)
-
usbinfo/dump.c (modified) (1 diff)
-
usbinfo/list.c (modified) (1 diff)
-
usbinfo/main.c (modified) (1 diff)
-
vdemo/vdemo.c (modified) (3 diffs)
-
vlaunch/Makefile (modified) (1 diff)
-
vlaunch/gfx/helenos.tga (added)
-
vlaunch/vlaunch.c (modified) (6 diffs)
-
vterm/vterm.c (modified) (2 diffs)
-
websrv/websrv.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
uspace/app/bdsh/cmds/modules/cat/cat.c
ra1e2df13 r25eec4ef 117 117 static void waitkey() 118 118 { 119 kbd_event_t ev; 119 cons_event_t ev; 120 kbd_event_t *kev; 120 121 121 122 while (true) { 122 if (!console_get_ kbd_event(console, &ev)) {123 if (!console_get_event(console, &ev)) { 123 124 return; 124 125 } 125 if (ev.type == KEY_PRESS) { 126 if (ev.key == KC_ESCAPE || ev.key == KC_Q) { 126 if (ev.type == CEV_KEY && ev.ev.key.type == KEY_PRESS) { 127 kev = &ev.ev.key; 128 129 if (kev->key == KC_ESCAPE || kev->key == KC_Q) { 127 130 should_quit = true; 128 131 return; 129 132 } 130 if ( ev.key == KC_C) {133 if (kev->key == KC_C) { 131 134 paging_enabled = false; 132 135 return; 133 136 } 134 if ( ev.key == KC_ENTER || ev.key == KC_SPACE ||135 ev.key == KC_PAGE_DOWN) {137 if (kev->key == KC_ENTER || kev->key == KC_SPACE || 138 kev->key == KC_PAGE_DOWN) { 136 139 return; 137 140 } -
uspace/app/bdsh/cmds/modules/cp/cp.c
ra1e2df13 r25eec4ef 152 152 153 153 while (true) { 154 kbd_event_t ev;154 cons_event_t ev; 155 155 console_flush(con); 156 console_get_ kbd_event(con, &ev);157 if ( (ev.type != KEY_PRESS)158 || (ev.mods & (KM_CTRL | KM_ALT)) != 0) {156 console_get_event(con, &ev); 157 if (ev.type != CEV_KEY || ev.ev.key.type != KEY_PRESS || 158 (ev.ev.key.mods & (KM_CTRL | KM_ALT)) != 0) { 159 159 continue; 160 160 } 161 161 162 switch(ev. key) {162 switch(ev.ev.key.key) { 163 163 case KC_Y: 164 164 printf("y\n"); -
uspace/app/bdsh/cmds/modules/ls/ls.c
ra1e2df13 r25eec4ef 315 315 { 316 316 if (stat(path, &de->s)) { 317 cli_error(CL_ENOENT, path);317 cli_error(CL_ENOENT, "%s", path); 318 318 return LS_BOGUS; 319 319 } -
uspace/app/bdsh/cmds/modules/sleep/sleep.c
ra1e2df13 r25eec4ef 114 114 int ret; 115 115 unsigned int argc; 116 useconds_t duration ;116 useconds_t duration = 0; 117 117 118 118 /* Count the arguments */ -
uspace/app/bdsh/compl.c
ra1e2df13 r25eec4ef 28 28 */ 29 29 30 #include < bool.h>30 #include <stdbool.h> 31 31 #include <dirent.h> 32 32 #include <errno.h> -
uspace/app/bdsh/input.c
ra1e2df13 r25eec4ef 41 41 #include <errno.h> 42 42 #include <assert.h> 43 #include < bool.h>43 #include <stdbool.h> 44 44 #include <tinput.h> 45 45 -
uspace/app/bnchmark/bnchmark.c
ra1e2df13 r25eec4ef 142 142 { 143 143 int rc; 144 umseconds_t milliseconds_taken ;144 umseconds_t milliseconds_taken = 0; 145 145 char *path = NULL; 146 146 measure_func_t fn = NULL; -
uspace/app/edit/edit.c
ra1e2df13 r25eec4ef 47 47 #include <macros.h> 48 48 #include <clipboard.h> 49 #include < bool.h>49 #include <stdbool.h> 50 50 51 51 #include "sheet.h" … … 80 80 tag_t sel_start; 81 81 82 /** Active keyboard modifiers */ 83 keymod_t keymod; 84 82 85 /** 83 86 * Ideal column where the caret should try to get. This is used … … 119 122 static void cursor_setvis(bool visible); 120 123 124 static void key_handle_press(kbd_event_t *ev); 121 125 static void key_handle_unmod(kbd_event_t const *ev); 122 126 static void key_handle_ctrl(kbd_event_t const *ev); … … 124 128 static void key_handle_shift_ctrl(kbd_event_t const *ev); 125 129 static void key_handle_movement(unsigned int key, bool shift); 130 131 static void pos_handle(pos_event_t *ev); 126 132 127 133 static int file_save(char const *fname); … … 182 188 int main(int argc, char *argv[]) 183 189 { 184 kbd_event_t ev;190 cons_event_t ev; 185 191 bool new_file; 186 192 int rc; … … 245 251 246 252 while (!done) { 247 console_get_ kbd_event(con, &ev);253 console_get_event(con, &ev); 248 254 pane.rflags = 0; 249 255 250 if (ev.type == KEY_PRESS) { 251 /* Handle key press. */ 252 if (((ev.mods & KM_ALT) == 0) && 253 ((ev.mods & KM_SHIFT) == 0) && 254 (ev.mods & KM_CTRL) != 0) { 255 key_handle_ctrl(&ev); 256 } else if (((ev.mods & KM_ALT) == 0) && 257 ((ev.mods & KM_CTRL) == 0) && 258 (ev.mods & KM_SHIFT) != 0) { 259 key_handle_shift(&ev); 260 } else if (((ev.mods & KM_ALT) == 0) && 261 ((ev.mods & KM_CTRL) != 0) && 262 (ev.mods & KM_SHIFT) != 0) { 263 key_handle_shift_ctrl(&ev); 264 } else if ((ev.mods & (KM_CTRL | KM_ALT | KM_SHIFT)) == 0) { 265 key_handle_unmod(&ev); 266 } 256 switch (ev.type) { 257 case CEV_KEY: 258 pane.keymod = ev.ev.key.mods; 259 if (ev.ev.key.type == KEY_PRESS) 260 key_handle_press(&ev.ev.key); 261 break; 262 case CEV_POS: 263 pos_handle(&ev.ev.pos); 264 break; 267 265 } 268 266 … … 286 284 287 285 return 0; 286 } 287 288 /* Handle key press. */ 289 static void key_handle_press(kbd_event_t *ev) 290 { 291 if (((ev->mods & KM_ALT) == 0) && 292 ((ev->mods & KM_SHIFT) == 0) && 293 (ev->mods & KM_CTRL) != 0) { 294 key_handle_ctrl(ev); 295 } else if (((ev->mods & KM_ALT) == 0) && 296 ((ev->mods & KM_CTRL) == 0) && 297 (ev->mods & KM_SHIFT) != 0) { 298 key_handle_shift(ev); 299 } else if (((ev->mods & KM_ALT) == 0) && 300 ((ev->mods & KM_CTRL) != 0) && 301 (ev->mods & KM_SHIFT) != 0) { 302 key_handle_shift_ctrl(ev); 303 } else if ((ev->mods & (KM_CTRL | KM_ALT | KM_SHIFT)) == 0) { 304 key_handle_unmod(ev); 305 } 288 306 } 289 307 … … 462 480 } 463 481 482 static void pos_handle(pos_event_t *ev) 483 { 484 coord_t bc; 485 spt_t pt; 486 bool select; 487 488 if (ev->type == POS_PRESS && ev->vpos < (unsigned)pane.rows) { 489 bc.row = pane.sh_row + ev->vpos; 490 bc.column = pane.sh_column + ev->hpos; 491 sheet_get_cell_pt(doc.sh, &bc, dir_before, &pt); 492 493 select = (pane.keymod & KM_SHIFT) != 0; 494 495 caret_move(pt, select, true); 496 } 497 } 498 464 499 /** Move caret while preserving or resetting selection. */ 465 500 static void caret_move(spt_t new_caret_pt, bool select, bool update_ideal_column) … … 592 627 static char *prompt(char const *prompt, char const *init_value) 593 628 { 594 kbd_event_t ev; 629 cons_event_t ev; 630 kbd_event_t *kev; 595 631 char *str; 596 632 wchar_t buffer[INFNAME_MAX_LEN + 1]; … … 612 648 613 649 while (!done) { 614 console_get_kbd_event(con, &ev); 615 616 if (ev.type == KEY_PRESS) { 650 console_get_event(con, &ev); 651 652 if (ev.type == CEV_KEY && ev.ev.key.type == KEY_PRESS) { 653 kev = &ev.ev.key; 654 617 655 /* Handle key press. */ 618 if ((( ev.mods & KM_ALT) == 0) &&619 ( ev.mods & KM_CTRL) != 0) {656 if (((kev->mods & KM_ALT) == 0) && 657 (kev->mods & KM_CTRL) != 0) { 620 658 ; 621 } else if (( ev.mods & (KM_CTRL | KM_ALT)) == 0) {622 switch ( ev.key) {659 } else if ((kev->mods & (KM_CTRL | KM_ALT)) == 0) { 660 switch (kev->key) { 623 661 case KC_ESCAPE: 624 662 return NULL; … … 634 672 break; 635 673 default: 636 if ( ev.c >= 32 && nc < max_len) {637 putchar( ev.c);674 if (kev->c >= 32 && nc < max_len) { 675 putchar(kev->c); 638 676 console_flush(con); 639 buffer[nc++] = ev.c;677 buffer[nc++] = kev->c; 640 678 } 641 679 break; -
uspace/app/edit/sheet.h
ra1e2df13 r25eec4ef 39 39 #include <adt/list.h> 40 40 #include <sys/types.h> 41 #include < bool.h>41 #include <stdbool.h> 42 42 43 43 /** Direction (in linear space) */ -
uspace/app/init/init.c
ra1e2df13 r25eec4ef 39 39 #include <stdarg.h> 40 40 #include <vfs/vfs.h> 41 #include < bool.h>41 #include <stdbool.h> 42 42 #include <errno.h> 43 43 #include <fcntl.h> … … 369 369 #ifdef CONFIG_START_BD 370 370 srv_start("/srv/ata_bd"); 371 srv_start("/srv/gxe_bd");372 371 #endif 373 372 -
uspace/app/klog/Makefile
ra1e2df13 r25eec4ef 29 29 30 30 USPACE_PREFIX = ../.. 31 LIBS = $(LIBCLUI_PREFIX)/libclui.a 32 EXTRA_CFLAGS = -I$(LIBCLUI_PREFIX) 31 33 BINARY = klog 32 34 -
uspace/app/klog/klog.c
ra1e2df13 r25eec4ef 48 48 #include <adt/list.h> 49 49 #include <adt/prodcons.h> 50 #include <tinput.h> 50 51 51 52 #define NAME "klog" … … 228 229 } 229 230 231 tinput_t *input = tinput_new(); 232 if (!input) { 233 fprintf(stderr, "%s: Could not create input\n", NAME); 234 return ENOMEM; 235 } 236 230 237 fibril_add_ready(fid); 231 238 event_unmask(EVENT_KLOG); 232 239 klog_update(); 233 240 234 task_retval(0); 235 async_manager(); 236 237 return 0; 241 tinput_set_prompt(input, "klog> "); 242 243 char *str; 244 while ((rc = tinput_read(input, &str)) == EOK) { 245 if (str_cmp(str, "") == 0) { 246 free(str); 247 continue; 248 } 249 250 klog_command(str, str_size(str)); 251 free(str); 252 } 253 254 if (rc == ENOENT) 255 rc = EOK; 256 257 return EOK; 238 258 } 239 259 -
uspace/app/mkbd/main.c
ra1e2df13 r25eec4ef 40 40 #include <errno.h> 41 41 #include <str_error.h> 42 #include < bool.h>42 #include <stdbool.h> 43 43 #include <getopt.h> 44 44 #include <devman.h> … … 178 178 179 179 while (1) { 180 kbd_event_t ev;181 bool ok = console_get_ kbd_event(con, &ev);180 cons_event_t ev; 181 bool ok = console_get_event(con, &ev); 182 182 if (!ok) { 183 183 printf("Connection with console broken: %s.\n", … … 186 186 } 187 187 188 if (ev.key == KC_ESCAPE) { 188 if (ev.type == CEV_KEY && ev.ev.key.type == KEY_PRESS && 189 ev.ev.key.key == KC_ESCAPE) { 189 190 break; 190 191 } -
uspace/app/mkexfat/exfat.h
ra1e2df13 r25eec4ef 34 34 #include <sys/types.h> 35 35 #include <stdint.h> 36 #include < bool.h>36 #include <stdbool.h> 37 37 38 38 #define EXFAT_FILENAME_LEN 255 -
uspace/app/mkexfat/mkexfat.c
ra1e2df13 r25eec4ef 46 46 #include <sys/types.h> 47 47 #include <sys/typefmt.h> 48 #include < bool.h>48 #include <stdbool.h> 49 49 #include <str.h> 50 50 #include <getopt.h> -
uspace/app/msim/arch_helenos/input.c
ra1e2df13 r25eec4ef 91 91 bool stdin_poll(char *key) 92 92 { 93 kbd_event_t ev;93 cons_event_t ev; 94 94 suseconds_t timeout = 0; 95 95 errno = EOK; 96 96 console_flush(input_prompt->console); 97 bool has_input = console_get_ kbd_event_timeout(input_prompt->console, &ev, &timeout);97 bool has_input = console_get_event_timeout(input_prompt->console, &ev, &timeout); 98 98 if (!has_input) { 99 99 return false; 100 100 } 101 101 102 if (ev.type != KEY_PRESS)102 if (ev.type != CEV_KEY || ev.ev.key.type != KEY_PRESS) 103 103 return false; 104 104 105 *key = ev. c;105 *key = ev.ev.key.c; 106 106 107 107 return true; -
uspace/app/netecho/netecho.c
ra1e2df13 r25eec4ef 243 243 if (verbose) 244 244 printf("accept()\n"); 245 socket_id = accept(listening_id, (void *) address_buf, &addrlen);245 socket_id = accept(listening_id, (void *) address_buf, &addrlen); 246 246 if (socket_id <= 0) { 247 247 socket_print_error(stderr, socket_id, "Socket accept: ", "\n"); … … 312 312 rc = sendto(socket_id, reply ? reply : data, reply ? reply_length : length, 0, address, addrlen); 313 313 if (rc != EOK) 314 socket_print_error(stderr, rc, "Socket send : ", "\n");314 socket_print_error(stderr, rc, "Socket sendto: ", "\n"); 315 315 } 316 316 } … … 394 394 return listening_id; 395 395 } 396 396 397 /* Bind the listening socket */ 398 rc = bind(listening_id, address, addrlen); 399 if (rc != EOK) { 400 socket_print_error(stderr, rc, "Socket bind: ", "\n"); 401 return rc; 402 } 403 397 404 /* if the stream socket is used */ 398 405 if (type == SOCK_STREAM) { … … 402 409 backlog = 3; 403 410 } 404 411 405 412 /* Set the backlog */ 406 413 rc = listen(listening_id, backlog); … … 409 416 return rc; 410 417 } 411 }412 413 /* Bind the listening socket */414 rc = bind(listening_id, address, addrlen);415 if (rc != EOK) {416 socket_print_error(stderr, rc, "Socket bind: ", "\n");417 return rc;418 418 } 419 419 -
uspace/app/nettest2/nettest2.c
ra1e2df13 r25eec4ef 45 45 #include <time.h> 46 46 #include <arg_parse.h> 47 #include < bool.h>47 #include <stdbool.h> 48 48 49 49 #include <net/in.h> -
uspace/app/nettest3/nettest3.c
ra1e2df13 r25eec4ef 63 63 port = 7; 64 64 65 data = (char *) "Hello World!";65 data = (char *) "Hello World!"; 66 66 size = str_size(data); 67 67 … … 98 98 99 99 printf("connect()\n"); 100 rc = connect(fd, (struct sockaddr *) &addr, sizeof(addr));100 rc = connect(fd, (struct sockaddr *) &addr, sizeof(addr)); 101 101 printf(" -> %d\n", rc); 102 102 if (rc != 0) … … 115 115 } while (rc > 0); 116 116 117 async_usleep(1000 *1000);117 async_usleep(1000 * 1000); 118 118 119 119 printf("closesocket()\n"); … … 124 124 } 125 125 126 127 126 /** @} 128 127 */ -
uspace/app/nterm/conn.c
ra1e2df13 r25eec4ef 33 33 */ 34 34 35 #include < bool.h>35 #include <stdbool.h> 36 36 #include <errno.h> 37 37 #include <fibril.h> -
uspace/app/nterm/nterm.c
ra1e2df13 r25eec4ef 33 33 */ 34 34 35 #include < bool.h>35 #include <stdbool.h> 36 36 #include <errno.h> 37 37 #include <io/console.h> … … 109 109 int main(int argc, char *argv[]) 110 110 { 111 kbd_event_t ev;111 cons_event_t ev; 112 112 int rc; 113 113 … … 129 129 done = false; 130 130 while (!done) { 131 console_get_ kbd_event(con, &ev);132 if (ev.type == KEY_PRESS)133 key_handle(&ev );131 console_get_event(con, &ev); 132 if (ev.type == CEV_KEY && ev.ev.key.type == KEY_PRESS) 133 key_handle(&ev.ev.key); 134 134 } 135 135 -
uspace/app/ping/ping.c
ra1e2df13 r25eec4ef 34 34 35 35 #include <async.h> 36 #include < bool.h>36 #include <stdbool.h> 37 37 #include <errno.h> 38 38 #include <fibril_synch.h> … … 188 188 { 189 189 console_ctrl_t *con; 190 kbd_event_t ev;190 cons_event_t ev; 191 191 192 192 con = console_init(stdin, stdout); … … 194 194 195 195 while (true) { 196 if (!console_get_ kbd_event(con, &ev))196 if (!console_get_event(con, &ev)) 197 197 break; 198 198 199 if (ev.type == KEY_PRESS && (ev.mods & (KM_ALT | KM_SHIFT)) == 200 0 && (ev.mods & KM_CTRL) != 0) { 199 if (ev.type == CEV_KEY && ev.ev.key.type == KEY_PRESS && 200 (ev.ev.key.mods & (KM_ALT | KM_SHIFT)) == 201 0 && (ev.ev.key.mods & KM_CTRL) != 0) { 201 202 /* Ctrl+key */ 202 if (ev. key == KC_Q) {203 if (ev.ev.key.key == KC_Q) { 203 204 ping_signal_done(); 204 205 return 0; -
uspace/app/stats/stats.c
ra1e2df13 r25eec4ef 44 44 #include <malloc.h> 45 45 #include <inttypes.h> 46 #include < bool.h>46 #include <stdbool.h> 47 47 #include <str.h> 48 48 #include <arg_parse.h> -
uspace/app/taskdump/symtab.c
ra1e2df13 r25eec4ef 267 267 continue; 268 268 269 if ( best_name == NULL || (saddr <= addr &&saddr > best_addr)) {269 if (saddr <= addr && (best_name == NULL || saddr > best_addr)) { 270 270 best_name = sname; 271 271 best_addr = saddr; -
uspace/app/taskdump/taskdump.c
ra1e2df13 r25eec4ef 47 47 #include <macros.h> 48 48 #include <assert.h> 49 #include < bool.h>49 #include <stdbool.h> 50 50 51 51 #include <symtab.h> -
uspace/app/tester/Makefile
ra1e2df13 r25eec4ef 29 29 30 30 USPACE_PREFIX = ../.. 31 LIBS = $(LIB EXT2_PREFIX)/libext2.a $(LIBBLOCK_PREFIX)/libblock.a $(LIBSOFTFLOAT_PREFIX)/libsoftfloat.a32 EXTRA_CFLAGS = -I$(LIBBLOCK_PREFIX) -I$(LIB EXT2_PREFIX) -I$(LIBSOFTFLOAT_PREFIX)31 LIBS = $(LIBBLOCK_PREFIX)/libblock.a $(LIBSOFTFLOAT_PREFIX)/libsoftfloat.a 32 EXTRA_CFLAGS = -I$(LIBBLOCK_PREFIX) -I$(LIBSOFTFLOAT_PREFIX) 33 33 BINARY = tester 34 34 … … 63 63 mm/mapping1.c \ 64 64 hw/misc/virtchar1.c \ 65 hw/serial/serial1.c \ 66 ext2/ext2_1.c 65 hw/serial/serial1.c 67 66 68 67 include $(USPACE_PREFIX)/Makefile.common -
uspace/app/tester/float/softfloat1.c
ra1e2df13 r25eec4ef 35 35 #include <div.h> 36 36 #include <comparison.h> 37 #include <bool.h> 37 #include <conversion.h> 38 #include <stdbool.h> 38 39 #include "../tester.h" 39 40 40 #define OPERANDS 641 #define OPERANDS 10 41 42 #define PRECISION 10000 42 43 … … 44 45 45 46 typedef int32_t cmptype_t; 46 typedef void (* float_op_t)(float, float, float *, float_t *); 47 typedef void (* double_op_t)(double, double, double *, double_t *); 47 48 typedef void (* uint_to_double_op_t)(unsigned int, double *, double_t *); 49 typedef void (* double_to_uint_op_t)(double, unsigned int *, unsigned int *); 50 typedef void (* float_binary_op_t)(float, float, float *, float_t *); 51 typedef void (* double_binary_op_t)(double, double, double *, double_t *); 48 52 typedef void (* double_cmp_op_t)(double, double, cmptype_t *, cmptype_t *); 49 typedef void (* template_t)(void *, unsigned, unsigned, cmptype_t *, 53 54 typedef void (* template_unary_t)(void *, unsigned, cmptype_t *, cmptype_t *); 55 typedef void (* template_binary_t)(void *, unsigned, unsigned, cmptype_t *, 50 56 cmptype_t *); 51 57 52 static float fop_a[OPERANDS] = 53 {3.5, -2.1, 100.0, 50.0, -1024.0, 0.0}; 54 55 static float fop_b[OPERANDS] = 56 {-2.1, 100.0, 50.0, -1024.0, 3.5, 0.0}; 57 58 static double dop_a[OPERANDS] = 59 {3.5, -2.1, 100.0, 50.0, -1024.0, 0.0}; 60 61 static double dop_b[OPERANDS] = 62 {-2.1, 100.0, 50.0, -1024.0, 3.5, 0.0}; 58 #define NUMBERS \ 59 3.5, -2.1, 100.0, 50.0, -1024.0, 0.0, 768.3156, 1080.499999, -600.0, 1.0 60 61 static float fop_a[OPERANDS] = { 62 NUMBERS 63 }; 64 65 static double dop_a[OPERANDS] = { 66 NUMBERS 67 }; 68 69 static unsigned int uop_a[OPERANDS] = { 70 4, -100, 100, 50, 1024, 0, 1000000, -1U, 0x80000000U, 500 71 }; 63 72 64 73 static cmptype_t cmpabs(cmptype_t a) … … 81 90 82 91 static void 83 float_template(void *f, unsigned i, unsigned j, cmptype_t *pic, 92 uint_to_double_template(void *f, unsigned i, cmptype_t *pic, cmptype_t *pisc) 93 { 94 double c; 95 double_t sc; 96 97 uint_to_double_op_t op = (uint_to_double_op_t) f; 98 99 op(uop_a[i], &c, &sc); 100 101 *pic = (cmptype_t) (c * PRECISION); 102 *pisc = (cmptype_t) (sc.val * PRECISION); 103 } 104 105 static void 106 double_to_uint_template(void *f, unsigned i, cmptype_t *pic, cmptype_t *pisc) 107 { 108 unsigned int c; 109 unsigned int sc; 110 111 double_to_uint_op_t op = (double_to_uint_op_t) f; 112 113 op(dop_a[i], &c, &sc); 114 115 *pic = (cmptype_t) c; 116 *pisc = (cmptype_t) sc; 117 } 118 119 120 static void 121 float_template_binary(void *f, unsigned i, unsigned j, cmptype_t *pic, 84 122 cmptype_t *pisc) 85 123 { … … 87 125 float_t sc; 88 126 89 float_ op_t op = (float_op_t) f;90 91 op(fop_a[i], fop_ b[j], &c, &sc);127 float_binary_op_t op = (float_binary_op_t) f; 128 129 op(fop_a[i], fop_a[j], &c, &sc); 92 130 93 131 *pic = (cmptype_t) (c * PRECISION); … … 96 134 97 135 static void 98 double_template (void *f, unsigned i, unsigned j, cmptype_t *pic,136 double_template_binary(void *f, unsigned i, unsigned j, cmptype_t *pic, 99 137 cmptype_t *pisc) 100 138 { … … 102 140 double_t sc; 103 141 104 double_ op_t op = (double_op_t) f;105 106 op(dop_a[i], dop_ b[j], &c, &sc);142 double_binary_op_t op = (double_binary_op_t) f; 143 144 op(dop_a[i], dop_a[j], &c, &sc); 107 145 108 146 *pic = (cmptype_t) (c * PRECISION); … … 116 154 double_cmp_op_t op = (double_cmp_op_t) f; 117 155 118 op(dop_a[i], dop_b[j], pis, piss); 119 } 120 121 static bool test_template(template_t template, void *f) 156 op(dop_a[i], dop_a[j], pis, piss); 157 } 158 159 static bool test_template_unary(template_unary_t template, void *f) 160 { 161 bool correct = true; 162 163 for (unsigned int i = 0; i < OPERANDS; i++) { 164 cmptype_t ic; 165 cmptype_t isc; 166 167 template(f, i, &ic, &isc); 168 cmptype_t diff = cmpabs(ic - isc); 169 170 if (diff != 0) { 171 TPRINTF("i=%u diff=%" PRIdCMPTYPE "\n", i, diff); 172 correct = false; 173 } 174 } 175 176 return correct; 177 } 178 179 static bool test_template_binary(template_binary_t template, void *f) 122 180 { 123 181 bool correct = true; … … 142 200 } 143 201 202 static void uint_to_double_operator(unsigned int a, double *pc, double_t *psc) 203 { 204 *pc = (double) a; 205 psc->data = uint_to_double(a); 206 } 207 208 static void 209 double_to_uint_operator(double a, unsigned int *pc, unsigned int *psc) 210 { 211 double_t sa; 212 213 sa.val = a; 214 215 *pc = (unsigned int) a; 216 *psc = double_to_uint(sa.data); 217 } 218 219 static void 220 double_to_int_operator(double a, unsigned int *pc, unsigned int *psc) 221 { 222 double_t sa; 223 224 sa.val = a; 225 226 *pc = (int) a; 227 *psc = double_to_int(sa.data); 228 } 229 144 230 static void float_add_operator(float a, float b, float *pc, float_t *psc) 145 231 { … … 267 353 const char *err = NULL; 268 354 269 if (!test_template (float_template, float_add_operator)) {355 if (!test_template_binary(float_template_binary, float_add_operator)) { 270 356 err = "Float addition failed"; 271 357 TPRINTF("%s\n", err); 272 358 } 273 if (!test_template (float_template, float_mul_operator)) {359 if (!test_template_binary(float_template_binary, float_mul_operator)) { 274 360 err = "Float multiplication failed"; 275 361 TPRINTF("%s\n", err); 276 362 } 277 if (!test_template (float_template, float_div_operator)) {363 if (!test_template_binary(float_template_binary, float_div_operator)) { 278 364 err = "Float division failed"; 279 365 TPRINTF("%s\n", err); 280 366 } 281 if (!test_template (double_template, double_add_operator)) {367 if (!test_template_binary(double_template_binary, double_add_operator)) { 282 368 err = "Double addition failed"; 283 369 TPRINTF("%s\n", err); 284 370 } 285 if (!test_template (double_template, double_mul_operator)) {371 if (!test_template_binary(double_template_binary, double_mul_operator)) { 286 372 err = "Double multiplication failed"; 287 373 TPRINTF("%s\n", err); 288 374 } 289 if (!test_template (double_template, double_div_operator)) {375 if (!test_template_binary(double_template_binary, double_div_operator)) { 290 376 err = "Double division failed"; 291 377 TPRINTF("%s\n", err); 292 378 } 293 if (!test_template (double_compare_template, double_cmp_operator)) {379 if (!test_template_binary(double_compare_template, double_cmp_operator)) { 294 380 err = "Double comparison failed"; 295 381 TPRINTF("%s\n", err); 296 382 } 383 if (!test_template_unary(uint_to_double_template, 384 uint_to_double_operator)) { 385 err = "Conversion from unsigned int to double failed"; 386 TPRINTF("%s\n", err); 387 } 388 if (!test_template_unary(double_to_uint_template, 389 double_to_uint_operator)) { 390 err = "Conversion from double to unsigned int failed"; 391 TPRINTF("%s\n", err); 392 } 393 if (!test_template_unary(double_to_uint_template, 394 double_to_int_operator)) { 395 err = "Conversion from double to signed int failed"; 396 TPRINTF("%s\n", err); 397 } 297 398 298 399 return err; -
uspace/app/tester/ipc/starve.c
ra1e2df13 r25eec4ef 62 62 break; 63 63 64 kbd_event_t ev;64 cons_event_t ev; 65 65 suseconds_t timeout = 0; 66 bool has_event = console_get_ kbd_event_timeout(console, &ev, &timeout);67 if (has_event && (ev.type == KEY_PRESS)) {68 TPRINTF("Key %d pressed, terminating.\n", ev. key);66 bool has_event = console_get_event_timeout(console, &ev, &timeout); 67 if (has_event && ev.type == CEV_KEY && ev.ev.key.type == KEY_PRESS) { 68 TPRINTF("Key %d pressed, terminating.\n", ev.ev.key.key); 69 69 break; 70 70 } -
uspace/app/tester/mm/common.c
ra1e2df13 r25eec4ef 343 343 344 344 area->addr = as_area_create(AS_AREA_ANY, size, 345 AS_AREA_WRITE | AS_AREA_READ );345 AS_AREA_WRITE | AS_AREA_READ | AS_AREA_CACHEABLE); 346 346 if (area->addr == AS_MAP_FAILED) { 347 347 free(area); -
uspace/app/tester/mm/common.h
ra1e2df13 r25eec4ef 37 37 38 38 #include <sys/types.h> 39 #include < bool.h>39 #include <stdbool.h> 40 40 #include <adt/list.h> 41 41 -
uspace/app/tester/mm/mapping1.c
ra1e2df13 r25eec4ef 43 43 44 44 void *result = as_area_create(AS_AREA_ANY, size, 45 AS_AREA_READ | AS_AREA_WRITE );45 AS_AREA_READ | AS_AREA_WRITE | AS_AREA_CACHEABLE); 46 46 if (result == AS_MAP_FAILED) 47 47 return NULL; -
uspace/app/tester/tester.c
ra1e2df13 r25eec4ef 74 74 #include "hw/serial/serial1.def" 75 75 #include "hw/misc/virtchar1.def" 76 #include "ext2/ext2_1.def"77 76 {NULL, NULL, NULL, false} 78 77 }; -
uspace/app/tester/tester.h
ra1e2df13 r25eec4ef 37 37 38 38 #include <sys/types.h> 39 #include < bool.h>39 #include <stdbool.h> 40 40 #include <stacktrace.h> 41 41 … … 106 106 extern const char *test_serial1(void); 107 107 extern const char *test_virtchar1(void); 108 extern const char *test_ext2_1(void);109 108 extern const char *test_devman1(void); 110 109 extern const char *test_devman2(void); -
uspace/app/tetris/scores.c
ra1e2df13 r25eec4ef 125 125 int j; 126 126 size_t off; 127 kbd_event_t ev; 127 cons_event_t ev; 128 kbd_event_t *kev; 128 129 129 130 clear_screen(); … … 141 142 while (1) { 142 143 console_flush(console); 143 if (!console_get_ kbd_event(console, &ev))144 if (!console_get_event(console, &ev)) 144 145 exit(1); 145 146 146 if (ev.type == KEY_RELEASE)147 if (ev.type != CEV_KEY || ev.ev.key.type == KEY_RELEASE) 147 148 continue; 148 149 149 if (ev.key == KC_ENTER || ev.key == KC_NENTER) 150 kev = &ev.ev.key; 151 152 if (kev->key == KC_ENTER || kev->key == KC_NENTER) 150 153 break; 151 154 152 if ( ev.key == KC_BACKSPACE) {155 if (kev->key == KC_BACKSPACE) { 153 156 if (i > 0) { 154 157 wchar_t uc; … … 166 169 scores[NUMSPOTS - 1].hs_name[off] = '\0'; 167 170 } 168 } else if ( ev.c != '\0') {171 } else if (kev->c != '\0') { 169 172 if (i < (MAXLOGNAME - 1)) { 170 if (chr_encode( ev.c, scores[NUMSPOTS - 1].hs_name,173 if (chr_encode(kev->c, scores[NUMSPOTS - 1].hs_name, 171 174 &off, STR_BOUNDS(MAXLOGNAME) + 1) == EOK) { 172 175 ++i; -
uspace/app/tetris/screen.c
ra1e2df13 r25eec4ef 61 61 #include <vfs/vfs.h> 62 62 #include <async.h> 63 #include < bool.h>63 #include <stdbool.h> 64 64 #include <io/console.h> 65 65 #include <io/style.h> … … 344 344 345 345 while (timeout > 0) { 346 kbd_event_t event;347 348 if (!console_get_ kbd_event_timeout(console, &event, &timeout))346 cons_event_t event; 347 348 if (!console_get_event_timeout(console, &event, &timeout)) 349 349 break; 350 350 } … … 376 376 377 377 while (c == 0) { 378 kbd_event_t event;379 380 if (!console_get_ kbd_event_timeout(console, &event, &timeleft)) {378 cons_event_t event; 379 380 if (!console_get_event_timeout(console, &event, &timeleft)) { 381 381 timeleft = 0; 382 382 return -1; 383 383 } 384 384 385 if (event.type == KEY_PRESS)386 c = event. c;385 if (event.type == CEV_KEY && event.ev.key.type == KEY_PRESS) 386 c = event.ev.key.c; 387 387 } 388 388 … … 398 398 399 399 while (c == 0) { 400 kbd_event_t event;401 402 if (!console_get_ kbd_event(console, &event))400 cons_event_t event; 401 402 if (!console_get_event(console, &event)) 403 403 return -1; 404 404 405 if (event.type == KEY_PRESS)406 c = event. c;405 if (event.type == CEV_KEY && event.ev.key.type == KEY_PRESS) 406 c = event.ev.key.c; 407 407 } 408 408 -
uspace/app/tetris/screen.h
ra1e2df13 r25eec4ef 58 58 #include <io/console.h> 59 59 #include <async.h> 60 #include < bool.h>60 #include <stdbool.h> 61 61 62 62 typedef struct { -
uspace/app/top/screen.c
ra1e2df13 r25eec4ef 556 556 557 557 while (c == 0) { 558 kbd_event_t event;558 cons_event_t event; 559 559 560 560 warning_timeleft -= timeleft; 561 if (!console_get_ kbd_event_timeout(console, &event, &timeleft)) {561 if (!console_get_event_timeout(console, &event, &timeleft)) { 562 562 timeleft = 0; 563 563 return -1; … … 565 565 warning_timeleft += timeleft; 566 566 567 if (event.type == KEY_PRESS)568 c = event. c;567 if (event.type == CEV_KEY && event.ev.key.type == KEY_PRESS) 568 c = event.ev.key.c; 569 569 } 570 570 -
uspace/app/trace/ipc_desc.c
ra1e2df13 r25eec4ef 49 49 { IPC_M_DATA_READ, "DATA_READ" }, 50 50 { IPC_M_DEBUG, "DEBUG" }, 51 52 /* Terminating entry */53 { 0, NULL }54 51 }; 52 53 size_t ipc_methods_len = sizeof(ipc_methods) / sizeof(ipc_m_desc_t); 55 54 56 55 /** @} -
uspace/app/trace/ipc_desc.h
ra1e2df13 r25eec4ef 42 42 43 43 extern ipc_m_desc_t ipc_methods[]; 44 extern size_t ipc_methods_len; 44 45 45 46 #endif -
uspace/app/trace/ipcp.c
ra1e2df13 r25eec4ef 140 140 void ipcp_init(void) 141 141 { 142 ipc_m_desc_t *desc;143 oper_t *oper;144 145 142 val_type_t arg_def[OPER_MAX_ARGS] = { 146 143 V_INTEGER, … … 162 159 proto_system = proto_new("system"); 163 160 164 desc = ipc_methods; 165 while (desc->number != 0) { 166 oper = oper_new(desc->name, OPER_MAX_ARGS, arg_def, V_INTEGER, 167 OPER_MAX_ARGS, arg_def); 168 proto_add_oper(proto_system, desc->number, oper); 169 170 ++desc; 161 for (size_t i = 0; i < ipc_methods_len; i++) { 162 oper_t *oper = oper_new(ipc_methods[i].name, OPER_MAX_ARGS, 163 arg_def, V_INTEGER, OPER_MAX_ARGS, arg_def); 164 proto_add_oper(proto_system, ipc_methods[i].number, oper); 171 165 } 172 166 -
uspace/app/trace/syscalls.c
ra1e2df13 r25eec4ef 46 46 47 47 [SYS_TASK_GET_ID] = { "task_get_id", 1, V_ERRNO }, 48 [SYS_TASK_SET_NAME] = { "task_set_name", 2, V_ERRNO }, 48 49 [SYS_FUTEX_SLEEP] = { "futex_sleep_timeout", 3, V_ERRNO }, 49 50 [SYS_FUTEX_WAKEUP] = { "futex_wakeup", 1, V_ERRNO }, … … 82 83 }; 83 84 85 const size_t syscall_desc_len = (sizeof(syscall_desc) / sizeof(sc_desc_t)); 86 84 87 /** @} 85 88 */ -
uspace/app/trace/syscalls.h
ra1e2df13 r25eec4ef 36 36 #define SYSCALLS_H_ 37 37 38 #include <stdbool.h> 39 #include <unistd.h> 40 38 41 #include "trace.h" 39 42 … … 45 48 46 49 extern const sc_desc_t syscall_desc[]; 50 extern const size_t syscall_desc_len; 51 52 static inline bool syscall_desc_defined(unsigned sc_id) 53 { 54 return (sc_id < syscall_desc_len && syscall_desc[sc_id].name != NULL); 55 } 47 56 48 57 #endif -
uspace/app/trace/trace.c
ra1e2df13 r25eec4ef 43 43 #include <mem.h> 44 44 #include <str.h> 45 #include < bool.h>45 #include <stdbool.h> 46 46 #include <loader/loader.h> 47 47 #include <io/console.h> … … 136 136 } 137 137 138 free(task_ldr);139 138 task_ldr = NULL; 140 139 … … 348 347 if ((display_mask & DM_SYSCALL) != 0) { 349 348 /* Print syscall name and arguments */ 350 printf("%s", syscall_desc[sc_id].name); 351 print_sc_args(sc_args, syscall_desc[sc_id].n_args); 349 if (syscall_desc_defined(sc_id)) { 350 printf("%s", syscall_desc[sc_id].name); 351 print_sc_args(sc_args, syscall_desc[sc_id].n_args); 352 } 353 else { 354 printf("unknown_syscall<%d>", sc_id); 355 print_sc_args(sc_args, 6); 356 } 352 357 } 353 358 } … … 372 377 if ((display_mask & DM_SYSCALL) != 0) { 373 378 /* Print syscall return value */ 374 rv_type = syscall_desc[sc_id].rv_type; 379 if (syscall_desc_defined(sc_id)) 380 rv_type = syscall_desc[sc_id].rv_type; 381 else 382 rv_type = V_PTR; 375 383 print_sc_retval(sc_rc, rv_type); 376 384 } … … 497 505 ldr = loader_connect(); 498 506 if (ldr == NULL) 499 return 0;507 return NULL; 500 508 501 509 /* Get task ID. */ … … 557 565 static int cev_fibril(void *arg) 558 566 { 567 cons_event_t event; 568 559 569 (void) arg; 560 570 … … 567 577 fibril_mutex_unlock(&state_lock); 568 578 569 if (!console_get_ kbd_event(console, &cev))579 if (!console_get_event(console, &event)) 570 580 return -1; 571 581 572 fibril_mutex_lock(&state_lock); 573 cev_valid = true; 574 fibril_condvar_broadcast(&state_cv); 575 fibril_mutex_unlock(&state_lock); 582 if (event.type == CEV_KEY) { 583 fibril_mutex_lock(&state_lock); 584 cev = event.ev.key; 585 cev_valid = true; 586 fibril_condvar_broadcast(&state_cv); 587 fibril_mutex_unlock(&state_lock); 588 } 576 589 } 577 590 } -
uspace/app/usbinfo/desctree.c
ra1e2df13 r25eec4ef 39 39 #include <errno.h> 40 40 #include <str_error.h> 41 #include < bool.h>41 #include <stdbool.h> 42 42 43 43 #include <usb/usb.h> -
uspace/app/usbinfo/dump.c
ra1e2df13 r25eec4ef 39 39 #include <errno.h> 40 40 #include <str_error.h> 41 #include < bool.h>41 #include <stdbool.h> 42 42 43 43 #include <usb/usb.h> -
uspace/app/usbinfo/list.c
ra1e2df13 r25eec4ef 40 40 #include <errno.h> 41 41 #include <str_error.h> 42 #include < bool.h>42 #include <stdbool.h> 43 43 #include <getopt.h> 44 44 #include <devman.h> -
uspace/app/usbinfo/main.c
ra1e2df13 r25eec4ef 39 39 #include <errno.h> 40 40 #include <str_error.h> 41 #include < bool.h>41 #include <stdbool.h> 42 42 #include <getopt.h> 43 43 #include <devman.h> -
uspace/app/vdemo/vdemo.c
ra1e2df13 r25eec4ef 33 33 */ 34 34 35 #include < bool.h>35 #include <stdbool.h> 36 36 #include <stdio.h> 37 37 #include <malloc.h> … … 110 110 { 111 111 if (argc >= 2) { 112 window_t *main_window = window_open(argv[1], true, true, "vdemo" );112 window_t *main_window = window_open(argv[1], true, true, "vdemo", 0, 0); 113 113 if (!main_window) { 114 114 printf("Cannot open main window.\n"); … … 141 141 lbl_action->cancel); 142 142 143 grid->add(grid, &lbl_action->label.widget, 0, 0, 1, 2);144 grid->add(grid, &btn_confirm->widget, 1, 0, 1, 1);143 grid->add(grid, &lbl_action->label.widget, 0, 0, 2, 1); 144 grid->add(grid, &btn_confirm->widget, 0, 1, 1, 1); 145 145 grid->add(grid, &btn_cancel->widget, 1, 1, 1, 1); 146 window_resize(main_window, 200, 7 0);146 window_resize(main_window, 200, 76); 147 147 148 148 window_exec(main_window); -
uspace/app/vlaunch/Makefile
ra1e2df13 r25eec4ef 35 35 36 36 SOURCES = \ 37 vlaunch.c 37 vlaunch.c \ 38 images.c 39 40 IMAGES = \ 41 gfx/helenos.tga 42 43 PRE_DEPEND = images.c images.h 44 EXTRA_CLEAN = images.c images.h 38 45 39 46 include $(USPACE_PREFIX)/Makefile.common 47 48 images.c images.h: $(IMAGES) 49 $(ROOT_PATH)/tools/mkarray.py images COMPOSITOR_IMAGES $^ -
uspace/app/vlaunch/vlaunch.c
ra1e2df13 r25eec4ef 33 33 */ 34 34 35 #include < bool.h>35 #include <stdbool.h> 36 36 #include <errno.h> 37 37 #include <stdio.h> … … 46 46 #include <button.h> 47 47 #include <label.h> 48 #include <canvas.h> 48 49 49 #define NAME "vlaunch" 50 #include <surface.h> 51 #include <source.h> 52 #include <drawctx.h> 53 #include <codec/tga.h> 54 55 #include "images.h" 56 57 #define NAME "vlaunch" 58 59 #define LOGO_WIDTH 196 60 #define LOGO_HEIGHT 66 50 61 51 62 static char *winreg = NULL; … … 97 108 } 98 109 110 surface_t *logo = decode_tga((void *) helenos_tga, helenos_tga_size, 0); 111 if (!logo) { 112 printf("Unable to decode logo.\n"); 113 return 1; 114 } 115 99 116 winreg = argv[1]; 100 window_t *main_window = window_open(argv[1], true, true, "vlaunch" );117 window_t *main_window = window_open(argv[1], true, true, "vlaunch", 0, 0); 101 118 if (!main_window) { 102 119 printf("Cannot open main window.\n"); … … 110 127 pixel_t lbl_fg = PIXEL(255, 0, 0, 0); 111 128 129 canvas_t *logo_canvas = create_canvas(NULL, LOGO_WIDTH, LOGO_HEIGHT, 130 logo); 112 131 label_t *lbl_caption = create_label(NULL, "Launch application:", 16, 113 132 lbl_bg, lbl_fg); … … 118 137 button_t *btn_vlaunch = create_button(NULL, "vlaunch", 16, btn_bg, 119 138 btn_fg); 120 grid_t *grid = create_grid(window_root(main_window), 4, 1, grd_bg);139 grid_t *grid = create_grid(window_root(main_window), 1, 5, grd_bg); 121 140 122 if ((!l bl_caption) || (!btn_vterm) || (!btn_vdemo) ||123 (!btn_v launch) || (!grid)) {141 if ((!logo_canvas) || (!lbl_caption) || (!btn_vterm) || 142 (!btn_vdemo) || (!btn_vlaunch) || (!grid)) { 124 143 window_close(main_window); 125 144 printf("Cannot create widgets.\n"); … … 131 150 sig_connect(&btn_vlaunch->clicked, NULL, on_vlaunch); 132 151 133 grid->add(grid, &lbl_caption->widget, 0, 0, 1, 1); 134 grid->add(grid, &btn_vterm->widget, 1, 0, 1, 1); 135 grid->add(grid, &btn_vdemo->widget, 2, 0, 1, 1); 136 grid->add(grid, &btn_vlaunch->widget, 3, 0, 1, 1); 152 grid->add(grid, &logo_canvas->widget, 0, 0, 1, 1); 153 grid->add(grid, &lbl_caption->widget, 0, 1, 1, 1); 154 grid->add(grid, &btn_vterm->widget, 0, 2, 1, 1); 155 grid->add(grid, &btn_vdemo->widget, 0, 3, 1, 1); 156 grid->add(grid, &btn_vlaunch->widget, 0, 4, 1, 1); 137 157 138 window_resize(main_window, 180, 130);158 window_resize(main_window, 210, 130 + LOGO_HEIGHT); 139 159 window_exec(main_window); 160 140 161 task_retval(0); 141 162 async_manager(); -
uspace/app/vterm/vterm.c
ra1e2df13 r25eec4ef 33 33 */ 34 34 35 #include < bool.h>35 #include <stdbool.h> 36 36 #include <stdio.h> 37 37 #include <io/pixel.h> … … 49 49 } 50 50 51 window_t *main_window = window_open(argv[1], true, true, "vterm" );51 window_t *main_window = window_open(argv[1], true, true, "vterm", 0, 0); 52 52 if (!main_window) { 53 53 printf("%s: Cannot open main window.\n", NAME); -
uspace/app/websrv/websrv.c
ra1e2df13 r25eec4ef 34 34 */ 35 35 36 #include < bool.h>36 #include <stdbool.h> 37 37 #include <errno.h> 38 38 #include <assert.h>
Note:
See TracChangeset
for help on using the changeset viewer.
