Prevent default ide behaviour



im doing a plugin to cloud9 as my final project for cs50 online course

now i tried this code to prevent the enter, up and down keys from changing the text when the suggestion menu is shown by the following

e.returnValue = false;
e.cancelBubble = true;
return false;

but it doesn’t work i think the ide code run before my plugin

so i tried to reverse what happened meaning return the cursor to where it was if he hit up/down and remove the new line when he hit enter but i don’t know how when i change the text or cursor position when the user move/write my work doesn’t have any affect

for example
he wrote pri the plugin changed it to printf he then pressed space it appears as "pri " not "printf "

here is my full code


are you trying to recreate the completion popup?


there are none on cs50


what do you mean? pressing ctrl-space should open the completion popup.
Also try to uncheck view>Less Comfortable to get full cloud9 ide.


i did that from day 1 :slight_smile:
i think that cloud 9 doesn’t support c only c++

anyway i have finished the project

if you know how i can publish it please tell me because when i try it tells me its currently disabled