Applescript

List all open Firefox windows

tell application "Firefox Developer Edition" to get the {id, name} of (every window whose name is not "")

Focus window by ID

tell application "Firefox Developer Edition" to activate window <id>
Edit