Commit Graph

41 Commits

Author SHA1 Message Date
Magne Sjaastad
9e41db33f5 Progress: optionally call QApplication::processEvents on progress updates
Add ProgressInfoEventProcessingBlocker

Co-authored-by: Kristian Bendiksen kristian.bendiksen@gmail.com
2024-09-11 12:48:54 +02:00
Magne Sjaastad
cfc97bb615 Revert "Progress: optionally call QApplication::processEvents on progress updates."
This reverts commit eb762fd122.
2024-09-10 08:18:37 +02:00
Kristian Bendiksen
eb762fd122 Progress: optionally call QApplication::processEvents on progress updates.
Fixes the missing updates of UI when running long tasks in main thread.
2024-09-09 14:15:28 +02:00
Kristian Bendiksen
b324fdb26b Close project if cancelling well path loading. 2024-08-16 15:46:22 +02:00
Kristian Bendiksen
0216d9b57b Remove QApplication::processEvents uses. 2024-08-16 15:46:22 +02:00
Kristian Bendiksen
bf2a852b4d Add cancellation of well path collection loading. 2024-08-16 15:46:22 +02:00
Magne Sjaastad
030688cff6
Several adjustments related to Qt6
* Avoid ambiguous definition during unity build on Windows
* Add missing include
* Add Qt6 to expressionparser
* Add Qt6 to nightcharts
* Replace forward define of QStringList with include <QStringList>
* Use toMSecsSinceEpoch
* Use setContentsMargins
2024-04-16 14:22:15 +02:00
Eirik Marthinsen
29d991159b AppFwk: Move include of windows.h to top of file
The include was located in the middle of a file inside a namespace caf
block and lead to ambiguous symbols when compiling with unity build and
Qt6. It is also considered good practice to have includes at the top.

The pragma warning disable is also removed as the warning seems to be
gone (and none of the other windows.h includes have it).

Closes #11327
2024-04-05 14:20:00 +02:00
Magne Sjaastad
ef637e3053
Move stream operator from AppEnum header
This PR will reduce the compile time of code using AppEnum. 

* AppEnum: Move QTextStream operator to avoid include of QTextStream
* Avoid use of iostream in cafAssert
rator to avoid include of QTextStream

Include file profiling shows that include of QTextStream is a performance issue. Create a non-templated base class for AppEnum. Implement the QTextStream operator for this interface.
2024-03-25 15:14:04 +01:00
Kristian Bendiksen
98796b0dd9 #10649 Fwk: Use collection.empty() instead of comparing with size 2023-09-27 10:16:37 +02:00
Magne Sjaastad
d23c6b4bb6
Janitor: Several code hygiene adjustments (#9981)
* Include all libraries in APP_FWK_LIBRARIES
* Several fixes detected by Static Code Analysis
* Remove unused code
* Add .clang.tidy
* Use QElapsedTimer
* Use horizontalAdvance
* Avoid | between enum of different classes
* Avoid illegal character
* Renaming and reorder of constructor initialization
2023-03-23 15:49:06 +01:00
jonjenssen
33e908dd94
Avoid progress window staying behind on Linux when loading summary data (#9774)
Adjust progress info usage in summary file loading
2023-02-01 08:46:22 +01:00
Magne Sjaastad
549118b6ad #7974 Progress Bar : Always delay display and increase threshold duration
Some users experience crash/hang situations related to display of Progress Bar dialog. This is related to implicit repaint of windows due to display or hide of a progress dialog.

To reduce the probability for error situations the following is improved:
- Increase the delay before the dialog is displayed
- Do not show the progress dialog immediately, wait until the delay duration is reached
2021-11-01 15:13:38 +01:00
Magne Sjaastad
bdc536dfc4 #6106 Apply clang-format on AppFwk 2020-06-19 08:00:01 +02:00
Magne Sjaastad
c31e4cbaaf #5505 Progress Bar : Control visibility of progress bar in Preferences 2020-02-11 11:43:31 +01:00
Gaute Lindkvist
922386c673
#4416 First implementation of gRPC-based Python interface
First implementation with Asynchronous gRPC server, a few services and some client python code.
2019-05-20 13:21:02 +02:00
Gaute Lindkvist
57b33b0d4c
First implementation of Headless (#4392)
* Revert "#4377 Octave : Use RiaLogging for error messages instead of QErrorMessage "

This reverts commit f758a8edb2.

* Revert "#4380 Preferences : Changing scene font size when geo mech view is open causes crash"

This reverts commit df62a41397.

* Revert "#4379 Documentation : Update command line parser for import of summary files"

This reverts commit d0b5357ed4.

* Unfinished WIP

* Builds but crashes

* Refactored code now builds and runs

* ResInsight can now run the unittests headless

* Can run some command files successfully

* Build on Linux

* Extra headless hack header

* Moved PdmUiItem hack to cpp file

* Fix headless crash in RimWellAllocationPlot

* Handle error gracefully if ExportSnapshots command is executed from console

* Add caf::QIconProvider and remove some hacks

* Also made the greying out of disabled icons work for a couple of cases where it didn't.

* Linux build fix

* #4380 Reimplement fix df62a41397 by @magnesj on top of Headless code changes

* #4379 Reintroduce kode from d0b5357ed4 by @magnesj

* #4377 Restore f758a8edb2 in new Headless code
2019-05-06 10:36:05 +02:00
Gaute Lindkvist
de2920c7c2 Add ProgressInfoBlocker and add to unit tests 2019-03-22 13:30:18 +01:00
Gaute Lindkvist
749e19a879 Create a simpler task system for handling sub tasks in progress dialog.
* Remove incrementProgressAndUpdateNextStep() method
2019-03-12 14:34:22 +01:00
Gaute Lindkvist
0fd51b2088 #4025 Show delayed action progress bar during contour map generation 2019-02-11 13:10:38 +01:00
Magne Sjaastad
1a7de264ca #4020 System : Define NOMINMAX before include of windows.h 2019-02-01 06:50:53 +01:00
Magne Sjaastad
6aa234cc9b AppFwk : Fix several warnings 2018-09-13 09:01:05 +02:00
Gaute Lindkvist
c33ec790ed Convenience method for cafProgressInfo to increment and set up next step. 2018-07-02 10:29:30 +02:00
Gaute Lindkvist
921c1f606d Set a minimum width for progress dialog 2018-06-20 11:46:19 +02:00
Gaute Lindkvist
8f0fb820a5 #3050 Add memory count to progress dialog. 2018-06-19 10:09:51 +02:00
Jacob Støren
9b9f9b2bf1 #2939 ProgressInfo: Reintroduce process envents, to update the progress dialog durig processing on linux/mac.
Introduced isActive and used this info to block sheduled redraw/display model regen when progress bar is active, to avoid unintended recursive behaviour resulting in crashes.
2018-05-21 23:46:35 +02:00
Magne Sjaastad
f9de64c538 AppFwk : Use freopen_s instead of freopen 2018-02-23 19:34:43 +01:00
Magne Sjaastad
3239c66f54 AppFwk (clang-tidy) : modernize-use-nullptr 2018-02-18 18:05:08 +01:00
Jacob Støren
160b4c263d #2237 AppFwk Progressinfo: Add better error reporting, and avoid asserts when unneccessary 2017-12-08 16:56:42 +01:00
Magne Sjaastad
3f55d4f1f0 AppFwk : ProgressDialog : Add window flags 2017-11-29 16:38:29 +01:00
Magne Sjaastad
6791600d03 #1260 Replaced assert() with CAF_ASSERT() in AppFwk 2017-03-08 08:19:51 +01:00
Magne Sjaastad
749ce8e8af #1292 Fixed CppCheck Issues in AppFwk/cafUserInterface 2017-03-06 19:15:33 +01:00
Jacob Støren
193193d35f caf::ProgressInfo: Added some more descriptions and warnings on misuse. Added debug helper variables. 2016-10-31 08:43:36 +01:00
Magne Sjaastad
d57db25820 AppFwk : Progress dialog is reset and closed instead of hidden when no longer needed 2016-10-04 11:03:53 +02:00
Jacob Støren
c84b7ab6d9 Proposed fix for some progressbar related crashes 2016-09-28 12:14:41 +02:00
Jacob Støren
644a4529d3 Experimental: Avoid QProcessEvent during progress dialog.
By having a non modal progress dialog and calling repaint directly.
2015-09-21 18:54:35 +02:00
Jacob Støren
8b5ea1aeb3 Excluded user input events from progressbar process events.
They are not needed, and might cause problems.
2015-09-01 17:19:01 +02:00
Magne Sjaastad
58149cbdb9 Copied in RPM/Fwk/AppFwk
Commented out use of stipple line, as VizFwk is not update yet
2015-07-29 14:19:43 +02:00
Jacob Støren
a338c6abda Improved documentation of the progressbar class 2015-06-03 12:07:35 +02:00
Magne Sjaastad
cbc3238180 Do not show progress info when running from unit tests 2014-04-25 09:59:41 +02:00
sigurdp
f64d9b7e64 Moved CAF to Fwk/AppFwk and moved/renamed VisualizationModules to Fwk/VizFwk 2013-09-20 16:01:20 +02:00