parameters: (from_client=0)
return_statement: return True
docstring: Sends the drawing path to all clients.
docstring_summary: Sends the drawing path to all clients.
docstring_tokens: Sends the drawing path to all clients .
function: def sendState__draw_path(from_client=0):
      """
      Sends the drawing path to all clients.
      """
  
      global state
  
      if config.VERBOSE:
          message = {}
          message["event"] = "enhanced_collabration_state__draw_path"
          message["path"] = state["draw"]["paths"][-1]
          message["draw"] = {}
          message["draw"]["path_color"] = state["draw"]["path_color"]
          
          util.verbose("api.collabration.sendState__draw_path()", message)
  
      for client in api.globalvars.httpServer.ws_clients:
          message = {}
          message["event"] = "enhanced_collabration_state__draw_path"
          message["path"] = state["draw"]["paths"][-1]
          message["is_from_me"] = (from_client == client.client_id)
          message["draw"] = {}
          message["draw"]["path_color"] = state["draw"]["path_color"]
          message_json = json.dumps(message)
  
          client.wsSend(message_json)
      
      return True
function_tokens: def sendState__draw_path ( from_client = 0 ) : global state if config . VERBOSE : message = { } message [ "event" ] = "enhanced_collabration_state__draw_path" message [ "path" ] = state [ "draw" ] [ "paths" ] [ - 1 ] message [ "draw" ] = { } message [ "draw" ] [ "path_color" ] = state [ "draw" ] [ "path_color" ] util . verbose ( "api.collabration.sendState__draw_path()" , message ) for client in api . globalvars . httpServer . ws_clients : message = { } message [ "event" ] = "enhanced_collabration_state__draw_path" message [ "path" ] = state [ "draw" ] [ "paths" ] [ - 1 ] message [ "is_from_me" ] = ( from_client == client . client_id ) message [ "draw" ] = { } message [ "draw" ] [ "path_color" ] = state [ "draw" ] [ "path_color" ] message_json = json . dumps ( message ) client . wsSend ( message_json ) return True