Removed compiler warnings in dock.c

This patch removes the compiler warnings for unused variables in the
file dock.c
Removed unused code in screen.c

This patch removes the unused code in screen.c.

The variable "dock_head", is defined, but not used. When we removes
the variable, then we can see that a lot of code is not used! so we
can remove it :-)

This patch also removes some extra curly brackets and join the variable
definition and the initialization in one line for some variables.