MCPcopy Create free account
hub / github.com/davidgiven/fluxengine / StartFormatting

Method StartFormatting

src/gui/browserpanel.cc:112–146  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

110 }
111
112 void StartFormatting() override
113 {
114 try
115 {
116 SetPage(MainWindow::PAGE_BROWSER);
117 PrepareConfig();
118
119 _filesystemModel->Clear(Path());
120 _filesystemCapabilities = 0;
121 _filesystemIsReadOnly = true;
122 _filesystemNeedsFlushing = false;
123
124 SetState(STATE_WORKING);
125
126 QueueJob(
127 [this]()
128 {
129 _filesystem = Filesystem::createFilesystemFromConfig();
130 _filesystemCapabilities = _filesystem->capabilities();
131 _filesystemIsReadOnly = _filesystem->isReadOnly();
132
133 runOnUiThread(
134 [&]()
135 {
136 wxCommandEvent e;
137 OnBrowserFormatButton(e);
138 });
139 });
140 }
141 catch (const ErrorException& e)
142 {
143 wxMessageBox(e.message, "Error", wxOK | wxICON_ERROR);
144 StartIdle();
145 }
146 }
147
148 void OnQueueEmpty() override
149 {

Callers

nothing calls this directly

Calls 5

PathClass · 0.70
runOnUiThreadFunction · 0.70
ClearMethod · 0.45
capabilitiesMethod · 0.45
isReadOnlyMethod · 0.45

Tested by

no test coverage detected