mirror of
https://github.com/radareorg/radare2.git
synced 2024-12-01 17:40:34 +00:00
Initial mouse support for visual tabs ##visual
This commit is contained in:
parent
155b9b52b4
commit
ec44465982
@ -6,6 +6,7 @@
|
||||
|
||||
static const char *help_msg_a[] = {
|
||||
"Usage:", "a", "[abdefFghoprxstc] [...]",
|
||||
"a", "", "alias for aai - analysis information",
|
||||
"a*", "", "same as afl*;ah*;ax*",
|
||||
"aa", "[?]", "analyze all (fcns + bbs) (aa0 to avoid sub renaming)",
|
||||
"a8", " [hexpairs]", "analyze bytes",
|
||||
@ -22,6 +23,7 @@ static const char *help_msg_a[] = {
|
||||
"ag", "[?] [options]", "draw graphs in various formats",
|
||||
"ah", "[?]", "analysis hints (force opcode size, ...)",
|
||||
"ai", " [addr]", "address information (show perms, stack, heap, ...)",
|
||||
"aj", "", "same as a* but in json (aflj)",
|
||||
"aL", "", "list all asm/anal plugins (e asm.arch=?)",
|
||||
"an"," [name] [@addr]","show/rename/create whatever flag/function is used at addr",
|
||||
"ao", "[?] [len]", "analyze Opcodes (or emulate it)",
|
||||
@ -9207,6 +9209,12 @@ static int cmd_anal(void *data, const char *input) {
|
||||
r_cons_printf ("No plugins for this analysis plugin\n");
|
||||
}
|
||||
break;
|
||||
case 'j': // "aj"
|
||||
r_core_cmd0 (core, "aflj");
|
||||
break;
|
||||
case 0: // "a"
|
||||
r_core_cmd0 (core, "aai");
|
||||
break;
|
||||
default:
|
||||
r_core_cmd_help (core, help_msg_a);
|
||||
#if 0
|
||||
|
@ -2868,7 +2868,7 @@ int __helpCb(void *user) {
|
||||
}
|
||||
|
||||
int __licenseCb(void *user) {
|
||||
r_cons_message ("Copyright 2006-2018 - pancake - LGPL");
|
||||
r_cons_message ("Copyright 2006-2019 - pancake - LGPL");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -2242,8 +2242,17 @@ R_API int r_core_visual_cmd(RCore *core, const char *arg) {
|
||||
if (ch < 2) {
|
||||
int x, y;
|
||||
if (r_cons_get_click (&x, &y)) {
|
||||
if (y == 1 && x < 20) {
|
||||
if (y == 1 && x < 40) {
|
||||
ch = ':';
|
||||
} else if (y == 2) {
|
||||
if (x < 2) {
|
||||
visual_closetab (core);
|
||||
} else if (x < 5) {
|
||||
visual_newtab (core);
|
||||
} else {
|
||||
visual_nexttab (core);
|
||||
}
|
||||
return 1;
|
||||
} else {
|
||||
ch = 'c';
|
||||
}
|
||||
|
@ -13,13 +13,13 @@ static char *__core_visual_tab_string(RCore *core, const char *kolor) {
|
||||
if (hex_cols < 4) {
|
||||
return strdup ("");
|
||||
}
|
||||
int i=0;
|
||||
int i = 0;
|
||||
char *str = NULL;
|
||||
int tabs = r_list_length (core->visual.tabs);
|
||||
if (scr_color > 0) {
|
||||
// TODO: use theme
|
||||
if (tabs > 0) {
|
||||
str = r_str_appendf (str, "%s___", kolor);
|
||||
str = r_str_appendf (str, "%s-+__", kolor);
|
||||
}
|
||||
for (i = 0; i < tabs;i++) {
|
||||
RCoreVisualTab *tab = r_list_get_n (core->visual.tabs, i);
|
||||
|
Loading…
Reference in New Issue
Block a user