////////////////////////////////////////////////////////////////////////////
//
// Editor key binds and other cool stuff 
//..........................................................................


Keyboard::Bind( "tab", "Game::ToggleSimulation()", 10 );

Keyboard::Bind( "left_ctrl s", "Game::SaveToFileWithoutDialog()", 10 );


Keyboard::Bind( ".", "Game::AddAWallPin()", 10 );
Keyboard::Bind( ",", "Game::AddAGamePin()", 10 );
Keyboard::Bind( "s", "Game::AddCollectable()", 10 );
Keyboard::Bind( "b", "Game::AddTheBall()", 10 );
Keyboard::Bind( "c", "Game::RandomDrawingColor()", 10 );
Keyboard::Bind( "o", "Game::ImportObject(data/editor/rocket_object.xml)", 10 );
Keyboard::Bind( "left_ctrl c", "Game::ExportObject(data/editor/copy_paste.tmp)", 10 );
Keyboard::Bind( "left_ctrl v", "Ui::PasteText();Game::ImportObject(data/editor/copy_paste.tmp)", 0 );
Keyboard::Bind( "right_ctrl c", "Game::ExportObject(data/editor/copy_paste.tmp)", 10 );
Keyboard::Bind( "right_ctrl v", "Ui::PasteText();Game::ImportObject(data/editor/copy_paste.tmp)", 0 );

Keyboard::Bind( "left_ctrl y", "Game::Redo()", 10 );
Keyboard::Bind( "left_ctrl z", "Game::Undo()", 10 );
Keyboard::Bind( "right_ctrl y", "Game::Redo()", 10 );
Keyboard::Bind( "right_ctrl z", "Game::Undo()", 10 );

Keyboard::BindOnDown( 	"left_shift", 	"Game::drawingToBackground=1;Game::movingShiftDown=1" );
Keyboard::BindOnUp( 	"left_shift", 	"Game::drawingToBackground=0;Game::movingShiftDown=0" );
Keyboard::BindOnDown( 	"right_shift", 	"Game::drawingToBackground=1;Game::movingShiftDown=1" );
Keyboard::BindOnUp( 	"right_shift", 	"Game::drawingToBackground=0;Game::movingShiftDown=0" );
Keyboard::BindOnDown( 	"left_alt", 	"Game::drawingStatic=1" );
Keyboard::BindOnUp( 	"left_alt", 	"Game::drawingStatic=0" );
Keyboard::BindOnDown( 	"left_ctrl", 	"Game::movingObjects=1" );
Keyboard::BindOnUp( 	"left_ctrl", 	"Game::movingObjects=0" );
Keyboard::BindOnDown( 	"right_ctrl", 	"Game::movingObjects=1" );
Keyboard::BindOnUp( 	"right_ctrl", 	"Game::movingObjects=0" );
Keyboard::BindOnDown(   "r", 		"Game::drawingRope=1" );
Keyboard::BindOnUp(	"r", 		"Game::drawingRope=0" );

// Keyboard::Bind( "x", "Game::ToggleDrawingStatic()", 0 );

// thanks v.dog for the colors :)
Keyboard::Bind( "1", "Game::SetDrawingColor( 204, 4, 6 )", 10 );
Keyboard::Bind( "2", "Game::SetDrawingColor( 230, 127, 7 )", 10 );
Keyboard::Bind( "3", "Game::SetDrawingColor( 230, 245, 13 )", 10 );
Keyboard::Bind( "4", "Game::SetDrawingColor( 3, 255, 5 )", 10 );
Keyboard::Bind( "5", "Game::SetDrawingColor( 1, 3, 255 )", 10 );
Keyboard::Bind( "6", "Game::SetDrawingColor( 1, 2, 3 )", 10 );
Keyboard::Bind( "7", "Game::SetDrawingColor( 126, 127, 128 )", 10 );
Keyboard::Bind( "8", "Game::SetDrawingColor( 245, 245, 245 )", 10 );
Keyboard::Bind( "9", "Game::SetDrawingColor( 127, 15, 0 )", 10 );
Keyboard::Bind( "0", "Game::SetDrawingColor( 15, 63, 0 )", 10 );

Keyboard::Bind( "page_up", "Game::NextDrawingColor()" );
Keyboard::Bind( "page_down", "Game::PrevDrawingColor()" );