[education/rkward] /: Fix enabling of "delete marked rows" action
Thomas Friedrichsmeier
null at kde.org
Thu Jul 28 20:20:11 BST 2022
Git commit 31ac59d7fcdb00546db9ba6c69feddaf30c79b30 by Thomas Friedrichsmeier.
Committed on 28/07/2022 at 19:19.
Pushed by tfry into branch 'master'.
Fix enabling of "delete marked rows" action
M +2 -0 ChangeLog
M +2 -4 rkward/dataeditor/twintable.cpp
https://invent.kde.org/education/rkward/commit/31ac59d7fcdb00546db9ba6c69feddaf30c79b30
diff --git a/ChangeLog b/ChangeLog
index b06f3a05..b61992f2 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,5 @@
+- Fixed: IRT Cronbach's Alpha did not work for subsets, if the data.frame name contains dots
+- Fixed: Action to remove several rows in data editor, simultaneously, always remained disabled
- Fixed: Workspace browser would not always show change, immediately, when object type changes
- Fixed: Crash when using the "Git blame" kate plugin
- Fixed: Problem installing R support package in some configurations
diff --git a/rkward/dataeditor/twintable.cpp b/rkward/dataeditor/twintable.cpp
index 62366fec..5e2585dc 100644
--- a/rkward/dataeditor/twintable.cpp
+++ b/rkward/dataeditor/twintable.cpp
@@ -1,6 +1,6 @@
/*
twintable.cpp - This file is part of RKWard (https://rkward.kde.org). Created: Tue Oct 29 2002
-SPDX-FileCopyrightText: 2002-2016 by Thomas Friedrichsmeier <thomas.friedrichsmeier at kdemail.net>
+SPDX-FileCopyrightText: 2002-2022 by Thomas Friedrichsmeier <thomas.friedrichsmeier at kdemail.net>
SPDX-FileContributor: The RKWard Team <rkward-devel at kde.org>
SPDX-License-Identifier: GPL-2.0-or-later
*/
@@ -281,8 +281,7 @@ void TwinTable::contextMenu (int row, int col, const QPoint& pos) {
int bottom = sel.bottom ();
if (bottom >= datamodel->trueRows ()) bottom = datamodel->trueRows () - 1;
- action_delete_rows->setEnabled (top > bottom);
- if (top > bottom) bottom = top;
+ action_delete_rows->setEnabled (bottom > top);
action_delete_rows->setText (i18n ("Delete marked rows (%1-%2)", (top+1), (bottom+1)));
} else {
action_delete_rows->setEnabled (false);
@@ -371,7 +370,6 @@ void TwinTable::deleteSelectedRows () {
int top = sel.top ();
int bottom = sel.bottom ();
if (bottom >= datamodel->trueRows ()) bottom = datamodel->trueRows () - 1;
- if (top > bottom) top = bottom;
datamodel->removeRows (top, bottom - top + 1);
} else {
More information about the rkward-tracker
mailing list