Skip to content

Things that should be getters/utility functions #198

Description

@joshua-dean

Making this an ongoing list rather than a bunch of isolated issues. Feel free to add more.

I'm listing the first name that comes to mind, not anything definitive. These are primarily to increase readability to maximum verbosity isn't always necessary. A lot of these fall under the "current subtask" so standardizing on an abbreviation like "cst" would be fine as long as it is documented.

  • ulabel.subtasks[st_key] -> ulabel.get_subtask(st_key)
  • ulabel.get_current_subtask().state -> ulabel.get_current_subtask_state() or ulabel.get_cst_state()
  • ulabel.get_current_subtask().state.is_in_progress -> ulabel.current_subtask_in_progress()
  • ulabel.get_current_subtask().state.is_in_brush_mode -> ulabel.currently_in_brush_mode()
  • ulabel.get_current_subtask().state.is_in_brush_mode -> ulabel.currently_in_erase_mode()
  • ulabel.get_current_subtask().annotations.access -> ulabel.get_current_annotations()
  • ulabel.get_current_subtask().state.visible_dialogs -> ulabel.get_visible_dialogs() (I think this implies current subtask, as others shouldn't produce dialogs, right?)
  • ulabel.get_current_subtask().annotations.access[this.get_current_subtask().state.active_id] -> ulabel.get_current_active_anno()
  • ulabel.get_current_subtask().actions.stream -> ulabel.get_current_action_stream()
  • $("#" + ulabel.config["container_id"]) -> ulabel.root_container_jq()
    • Maybe also a ulabel.root_container() for document.getElementById

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions