Added select mode.
This commit is contained in:
@@ -211,6 +211,11 @@ html {
|
||||
}
|
||||
}
|
||||
|
||||
.btn-check:checked + .dropdown-item, :not(.btn-check) + .dropdown-item:active {
|
||||
color: #fff;
|
||||
background-color: #0d6efd;
|
||||
}
|
||||
|
||||
/*Media Queries*/
|
||||
@media (max-width: 576px) {
|
||||
.lubelogger-tab {
|
||||
@@ -282,6 +287,13 @@ html {
|
||||
|
||||
.table-context-menu {
|
||||
z-index: 1030;
|
||||
box-shadow: 0 12px 15px 0 rgba(0, 0, 0, 0.24);
|
||||
}
|
||||
.table-context-menu-mobile {
|
||||
position: absolute;
|
||||
left: 1vw;
|
||||
bottom: 1vw;
|
||||
width:98vw;
|
||||
}
|
||||
|
||||
input[type="file"] {
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -960,8 +960,9 @@ function rangeMouseDown(e) {
|
||||
if (isRightClick(e)) {
|
||||
return;
|
||||
}
|
||||
var contextMenuAction = $(e.target).is(".table-context-menu > li > .dropdown-item")
|
||||
if (!(e.ctrlKey || e.metaKey) && !contextMenuAction) {
|
||||
var contextMenuAction = $(e.target).is(".table-context-menu > li > .dropdown-item");
|
||||
var selectMode = $("#chkSelectMode").length > 0 ? $("#chkSelectMode").is(":checked") : false;
|
||||
if (!(e.ctrlKey || e.metaKey || selectMode) && !contextMenuAction) {
|
||||
clearSelectedRows();
|
||||
}
|
||||
isDragging = true;
|
||||
@@ -984,7 +985,7 @@ function stopEvent() {
|
||||
}
|
||||
function rangeMouseUp(e) {
|
||||
if ($(".table-context-menu").length > 0) {
|
||||
$(".table-context-menu").hide();
|
||||
$(".table-context-menu").fadeOut("fast");
|
||||
}
|
||||
if (isRightClick(e)) {
|
||||
return;
|
||||
@@ -1029,7 +1030,8 @@ function showTableContextMenu(e) {
|
||||
if (getDeviceIsTouchOnly()) {
|
||||
return;
|
||||
}
|
||||
$(".table-context-menu").show();
|
||||
$(".table-context-menu").removeClass('table-context-menu-mobile');
|
||||
$(".table-context-menu").fadeIn("fast");
|
||||
determineContextMenuItems();
|
||||
$(".table-context-menu").css({
|
||||
position: "absolute",
|
||||
@@ -1090,7 +1092,8 @@ function getMenuPosition(mouse, direction, scrollDir) {
|
||||
return position;
|
||||
}
|
||||
function handleTableRowClick(e, callBack, rowId) {
|
||||
if (!(event.ctrlKey || event.metaKey)) {
|
||||
var selectMode = $("#chkSelectMode").length > 0 ? $("#chkSelectMode").is(":checked") : false;
|
||||
if (!(event.ctrlKey || event.metaKey || selectMode)) {
|
||||
callBack(rowId);
|
||||
} else if (!$(e).hasClass('table-active')) {
|
||||
addToSelectedRows($(e).attr('data-rowId'));
|
||||
@@ -1107,13 +1110,9 @@ function showTableContextMenuForMobile(e, xPosition, yPosition) {
|
||||
$(e).addClass('table-active');
|
||||
shakeTableRow(e);
|
||||
} else {
|
||||
$(".table-context-menu").show();
|
||||
$(".table-context-menu").addClass('table-context-menu-mobile');
|
||||
$(".table-context-menu").fadeIn("fast");
|
||||
determineContextMenuItems();
|
||||
$(".table-context-menu").css({
|
||||
position: "absolute",
|
||||
left: getMenuPosition(xPosition, 'width', 'scrollLeft'),
|
||||
top: getMenuPosition(yPosition, 'height', 'scrollTop')
|
||||
});
|
||||
}
|
||||
}
|
||||
function shakeTableRow(e) {
|
||||
|
||||
Reference in New Issue
Block a user