Commit Graph

14 Commits

Author SHA1 Message Date
ispyisail 2266497b0b Write the move button tooltips in French, the tr() source language
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-24 22:20:43 +12:00
Shane Ringrose dcb79b6553 fix(terminal-strip): free-terminal move button disabled and unresponsive
Three bugs stacked to produce the symptom in issue #409 (move button does
nothing):

1. selectionChanged() was declared in freeterminaleditor.h but had no body
   and was never connected to the selection model, so the move button had no
   awareness of whether a terminal was selected. The button could appear
   enabled with nothing selected, then silently return early in
   on_m_move_pb_clicked() at the real_t_vector.isEmpty() guard.

2. The dataChanged→setDisabledMove(true) connection was a one-way trap: any
   cell edit (including accidentally opening and closing a type/function
   combo, or toggling LED back to its current value) permanently disabled the
   move button until reload() was called. There was no tooltip explaining why
   the button was greyed out, so the user had no way to recover.

3. FreeTerminalModel::setData() for LED_CELL had no change guard, unlike
   LABEL_CELL which checks label != value. Clicking the LED combo while it
   was already at the same value still emitted dataChanged and triggered the
   disable.

Fix:
- Implement selectionChanged() to enable the move controls only when at
  least one row is selected AND there are no pending (yellow) edits.
- Connect it to both selectionModel::selectionChanged and model::dataChanged
  so the button state is always consistent with actual UI state.
- Route reload()'s re-enable through selectionChanged() instead of calling
  setDisabledMove(false) directly, so the selection state is respected
  immediately after a move.
- Add a tooltip to m_move_pb explaining the disabled state.
- Add the missing change guard to LED_CELL in setData().

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-09-24 22:20:43 +12:00
Laurent Trinques 4044d04cc5 One year
Auto-build doxygen docs / doxygen (push) Has been cancelled
Auto-build doxygen docs / deploy (push) Has been cancelled
2026-01-16 15:24:35 +01:00
joshua f83a5b3a79 Merge branch 'terminal_strip' 2025-10-15 23:30:54 +02:00
joshua d711d8fb4a Terminal strip editor can now edit multiple project.
Before this this commit the terminal strip editor couldn't only work on
the first project opened into this editor, all other project opened
after couldn't be edited.
This is now past, terminal strip editor can now edit every project open
in QElectroTech.
2025-06-11 22:43:41 +02:00
Laurent Trinques 77bfe84a4c One year 2025-01-04 13:37:40 +01:00
plc-user b3ac3c82af fixed indentations of the remaining *.cpp/*.h files 2024-05-02 08:39:27 +02:00
Laurent Trinques e73cf633ce 2023->2024 2024-03-29 10:09:48 +01:00
Laurent Trinques 9afef79629 Update Copyright date 2023-01-01 17:05:57 +01:00
joshua 2a307a74da Improve execution time of some actions.
Improve the execution time when we add, change or remove
several terminals to/from terminal strip.
2022-06-23 21:36:24 +02:00
joshua 6197d0215a Several real terminal can be added to terminal strip in one shot
User can select several real terminals in the free terminal editor
and add it with one operation on a terminal strip.
2022-04-08 20:48:32 +02:00
joshua c4b0c1435c The free terminal properties can be edited by batch. 2022-03-25 19:49:31 +01:00
joshua a4445c411d Change made inside the free terminal table can be applied 2022-03-25 19:25:46 +01:00
joshua 9cbc3a2265 Add table widget and item model for free terminal
WIP, the change made in the table widget can't be applied.
2022-03-12 19:07:49 +01:00