Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
fractal
fractal
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 233
    • Issues 233
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 5
    • Merge Requests 5
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • GNOME
  • fractalfractal
  • Merge Requests
  • !647

Merged
Opened Oct 25, 2020 by Alejandro Domínguez@aledomuDeveloper

Manage app state in a reactive single-threaded glib loop

  • Overview 1
  • Commits 10
  • Pipelines 19
  • Changes 61

Right now we have a global mutex holding the state of the whole application, both for the model and the widget tree. This MR turns that mutex into a reactive loop that brings the right execution context for operations on the state and forces it, and at the same time it allows to define any set of operations atomically.

This loop can be used from any event handler as-is, so this paves the way to remove all Rc<RefCell<T>> and weak pointer stuff and at the same time it makes access and mutation to the state from other threads panic-free, while avoiding most deadlocks because it prevents the caller from taking any return value directly.

Edited Dec 04, 2020 by Alejandro Domínguez
Assignee
Assign to
Reviewer
Request review from
None
Milestone
None
Assign milestone
Time tracking
Reference: GNOME/fractal!647
Source branch: frp-channel