Hi,
The following script should do the trick. I've used cliclick because the “click at“ command doesn't seem to work any more under Mavericks (see this post for example).
tell application "System Events" to tell process "Dropbox"
set {x, y} to position of menu bar item 1 of menu bar 2
set {x, y} to {x + 13, y + 11} -- center of menu icon
end tell
set cliclick to "/usr/local/bin/cliclick "
do shell script cliclick & "c:" & x & "," & y & " w:250"
set {x, y} to {x + 135, y + 251} -- center of wheel
do shell script cliclick & "c:" & x & "," & y & " w:250"
set {x, y} to {x + 85, y + 102} -- center of menu item
do shell script cliclick & "c:" & x & "," & y
If you prefer, you might also use this more concise version of the script:
tell application "System Events" to tell process "Dropbox"
set {x, y} to position of menu bar item 1 of menu bar 2
end tell
do shell script "/usr/local/bin/cliclick " & "c:" & (x + 13) & "," & (y + 11) & " w:250" & " c:" & (x + 148) & "," & (y + 262) & " w:250" & " c:" & (x + 233) & "," & (y + 364)
Hope it can help.