diff options
author | Ricki Myers <antihc3@gmail.com> | 2008-03-04 21:50:02 +0300 |
---|---|---|
committer | Ricki Myers <antihc3@gmail.com> | 2008-03-04 21:50:02 +0300 |
commit | 8b5a5b71d53a139212bd6bfb630e3ea87b533727 (patch) | |
tree | e53e2c5d73c9f1cc50a38259a1cb768c53410673 /source/blender/src/drawtext.c | |
parent | b7bfa641ca52b852d885cb401a08fc904f5a5849 (diff) |
Fix bug where if you selected something then left clicked you would lose the selection buffer.
now when you left click it checks to see if there is text selected
Diffstat (limited to 'source/blender/src/drawtext.c')
-rw-r--r-- | source/blender/src/drawtext.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/src/drawtext.c b/source/blender/src/drawtext.c index 4751882a3ae..dec2ff5dacd 100644 --- a/source/blender/src/drawtext.c +++ b/source/blender/src/drawtext.c @@ -1531,9 +1531,11 @@ void winqreadtextspace(ScrArea *sa, void *spacedata, BWinEvent *evt) do_textscroll(st, 2); } else { do_selection(st, G.qual&LR_SHIFTKEY); - buffer = txt_sel_to_buf(text); - putClipboard((GHOST_TInt8*)buffer, 1); - MEM_freeN(buffer); + if (txt_has_sel(text)) { + buffer = txt_sel_to_buf(text); + putClipboard((GHOST_TInt8*)buffer, 1); + MEM_freeN(buffer); + } do_draw= 1; } } |