Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2010-10-14 03:46:42 +0400
committerCampbell Barton <ideasman42@gmail.com>2010-10-14 03:46:42 +0400
commit99711586482f2b23651983ed7dd69e138e616480 (patch)
tree1a213f682b9bc4e5ab699af668e6046f15f63b97 /source/blender/editors/space_console/console_ops.c
parentbe32cf8b3218eb0d52eadc99d31f12ed0bbc2ec7 (diff)
use UNUSED() macro for the console space + minor changes to args.
Diffstat (limited to 'source/blender/editors/space_console/console_ops.c')
-rw-r--r--source/blender/editors/space_console/console_ops.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/source/blender/editors/space_console/console_ops.c b/source/blender/editors/space_console/console_ops.c
index c36cbc38640..2b419b0a833 100644
--- a/source/blender/editors/space_console/console_ops.c
+++ b/source/blender/editors/space_console/console_ops.c
@@ -194,7 +194,7 @@ static ConsoleLine *console_scrollback_add(const bContext *C, ConsoleLine *from)
}
#endif
-static ConsoleLine *console_lb_add_str__internal(ListBase *lb, const bContext *C, char *str, int own)
+static ConsoleLine *console_lb_add_str__internal(ListBase *lb, char *str, int own)
{
ConsoleLine *ci= MEM_callocN(sizeof(ConsoleLine), "ConsoleLine Add");
if(own) ci->line= str;
@@ -205,14 +205,13 @@ static ConsoleLine *console_lb_add_str__internal(ListBase *lb, const bContext *C
BLI_addtail(lb, ci);
return ci;
}
-ConsoleLine *console_history_add_str(const bContext *C, char *str, int own)
+ConsoleLine *console_history_add_str(SpaceConsole *sc, char *str, int own)
{
- return console_lb_add_str__internal(&CTX_wm_space_console(C)->history, C, str, own);
+ return console_lb_add_str__internal(&sc->history, str, own);
}
-ConsoleLine *console_scrollback_add_str(const bContext *C, char *str, int own)
+ConsoleLine *console_scrollback_add_str(SpaceConsole *sc, char *str, int own)
{
- SpaceConsole *sc= CTX_wm_space_console(C);
- ConsoleLine *ci= console_lb_add_str__internal(&sc->scrollback, C, str, own);
+ ConsoleLine *ci= console_lb_add_str__internal(&sc->scrollback, str, own);
console_select_offset(sc, ci->len + 1);
return ci;
}
@@ -627,7 +626,7 @@ static int history_append_exec(bContext *C, wmOperator *op)
}
}
- ci= console_history_add_str(C, str, 1); /* own the string */
+ ci= console_history_add_str(sc, str, 1); /* own the string */
console_select_offset(sc, ci->len - prev_len);
console_line_cursor_set(ci, cursor);
@@ -663,7 +662,7 @@ static int scrollback_append_exec(bContext *C, wmOperator *op)
char *str= RNA_string_get_alloc(op->ptr, "text", NULL, 0); /* own this text in the new line, dont free */
int type= RNA_enum_get(op->ptr, "type");
- ci= console_scrollback_add_str(C, str, 1); /* own the string */
+ ci= console_scrollback_add_str(sc, str, 1); /* own the string */
ci->type= type;
console_scrollback_limit(sc);
@@ -698,7 +697,7 @@ void CONSOLE_OT_scrollback_append(wmOperatorType *ot)
}
-static int copy_exec(bContext *C, wmOperator *op)
+static int copy_exec(bContext *C, wmOperator *UNUSED(op))
{
SpaceConsole *sc= CTX_wm_space_console(C);
int buf_len;
@@ -779,7 +778,7 @@ void CONSOLE_OT_copy(wmOperatorType *ot)
/* properties */
}
-static int paste_exec(bContext *C, wmOperator *op)
+static int paste_exec(bContext *C, wmOperator *UNUSED(op))
{
SpaceConsole *sc= CTX_wm_space_console(C);
ConsoleLine *ci= console_history_verify(C);
@@ -834,7 +833,8 @@ typedef struct SetConsoleCursor {
int sel_init;
} SetConsoleCursor;
-static void set_cursor_to_pos(SpaceConsole *sc, ARegion *ar, SetConsoleCursor *scu, int mval[2], int sel)
+// TODO, cursor placement without selection
+static void set_cursor_to_pos(SpaceConsole *sc, ARegion *ar, SetConsoleCursor *scu, int mval[2], int UNUSED(sel))
{
int pos;
pos= console_char_pick(sc, ar, NULL, mval);
@@ -869,7 +869,7 @@ static void console_modal_select_apply(bContext *C, wmOperator *op, wmEvent *eve
ED_area_tag_redraw(CTX_wm_area(C));
}
-static void set_cursor_exit(bContext *C, wmOperator *op)
+static void set_cursor_exit(bContext *UNUSED(C), wmOperator *op)
{
// SpaceConsole *sc= CTX_wm_space_console(C);
SetConsoleCursor *scu= op->customdata;