adding dropping and clearing functionality