code text selection
This commit is contained in:
parent
0bbda15e1c
commit
3233d48861
22
src/code.c
22
src/code.c
|
@ -996,6 +996,8 @@ static void processGestures(Code* code)
|
||||||
|
|
||||||
static void processMouse(Code* code)
|
static void processMouse(Code* code)
|
||||||
{
|
{
|
||||||
|
tic_mem* tic = code->tic;
|
||||||
|
|
||||||
if(checkMousePos(&code->rect))
|
if(checkMousePos(&code->rect))
|
||||||
{
|
{
|
||||||
setCursor(tic_cursor_ibeam);
|
setCursor(tic_cursor_ibeam);
|
||||||
|
@ -1024,16 +1026,16 @@ static void processMouse(Code* code)
|
||||||
char* position = code->cursor.position;
|
char* position = code->cursor.position;
|
||||||
setCursorPosition(code, x + code->scroll.x, y + code->scroll.y);
|
setCursorPosition(code, x + code->scroll.x, y + code->scroll.y);
|
||||||
|
|
||||||
// if(SDL_GetModState() & KMOD_SHIFT)
|
if(tic->api.key(tic, tic_key_shift))
|
||||||
// {
|
{
|
||||||
// code->cursor.selection = code->cursor.position;
|
code->cursor.selection = code->cursor.position;
|
||||||
// code->cursor.position = position;
|
code->cursor.position = position;
|
||||||
// }
|
}
|
||||||
// else if(!code->cursor.mouseDownPosition)
|
else if(!code->cursor.mouseDownPosition)
|
||||||
// {
|
{
|
||||||
// code->cursor.selection = code->cursor.position;
|
code->cursor.selection = code->cursor.position;
|
||||||
// code->cursor.mouseDownPosition = code->cursor.position;
|
code->cursor.mouseDownPosition = code->cursor.position;
|
||||||
// }
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue