UI: Programs: Improve action's tool-tip

This commit is contained in:
Nodir Temirkhodjaev 2024-05-20 11:24:52 +03:00
parent f8479c7bbd
commit 02c7b9d255

View File

@ -188,7 +188,7 @@ QVariant dataDisplayName(const AppRow &appRow, int role)
: QString());
}
QVariant dataDisplayAction(const AppRow &appRow, int /*role*/)
QVariant dataDisplayAction(const AppRow &appRow, int role)
{
if (appRow.killProcess)
return AppListModel::tr("Kill Process");
@ -196,6 +196,9 @@ QVariant dataDisplayAction(const AppRow &appRow, int /*role*/)
if (appRow.blocked)
return AppListModel::tr("Block");
if (role == Qt::ToolTipRole && appRow.lanOnly)
return AppListModel::tr("Block Internet Traffic");
return AppListModel::tr("Allow");
}