@@ -534,9 +534,10 @@ Class LV_Rows extends LV_Rows.LV_EX
534534; ScrollDelay: Delay in miliseconds for AutoScroll. Default is 100ms.
535535; LineThick: Thickness of the destination bar in pixels. Default is 2px.
536536; Color: Color of destination bar. Default is "Black".
537+ ; Drop: Set to False to disable automatically dropping selected rows.
537538; Return: The destination row number.
538539; =======================================================================================
539- Drag(DragButton := " D" , AutoScroll := true , ScrollDelay := 100 , LineThick := 2 , Color := " Black" )
540+ Drag(DragButton := " D" , AutoScroll := true , ScrollDelay := 100 , LineThick := 2 , Color := " Black" , Drop := true )
540541 {
541542 Static LVIR_LABEL := 0x0002
542543 Static LVM_GETITEMCOUNT := 0x1004
@@ -633,9 +634,9 @@ Class LV_Rows extends LV_Rows.LV_EX
633634 }
634635 }
635636
636- If (DragButton = " LButton" && LV_currRow)
637+ Gui , MarkLine:Cancel
638+ If (Drop && DragButton = " LButton" && LV_currRow)
637639 {
638- Gui , MarkLine:Cancel
639640 CopyData := this.CopyData.Clone ()
640641 Lines := this.Copy()
641642 , this.Paste(LV_currRow)
@@ -975,7 +976,10 @@ Class LV_Rows extends LV_Rows.LV_EX
975976; =======================================================================================
976977 RefreshGroups(Collapsed := "" )
977978 {
978- GroupStates := []
979+ GroupsEnabled := this.IsGroupViewEnabled()
980+ , this.EnableGroupView(false )
981+
982+ , GroupStates := []
979983 Gui , Listview , % this.LVHwnd
980984 For e, g in this.Handle.GroupsArray
981985 {
@@ -989,7 +993,7 @@ Class LV_Rows extends LV_Rows.LV_EX
989993 If (this.Handle.GroupsArray[GrNum].Row = A_Index )
990994 {
991995 Group := this.Handle.GroupsArray[GrNum]
992- this.GroupInsert(Group.ID, Group.Name )
996+ , this.GroupInsert(Group.ID, Group.Name )
993997 , Styles := ! this.Collapsible ? []
994998 : Collapsed = "" ? [" Collapsible" , GroupStates[GrNum]]
995999 : Collapsed ? [" Collapsible" , " Collapsed" ]
@@ -999,6 +1003,7 @@ Class LV_Rows extends LV_Rows.LV_EX
9991003 }
10001004 this.SetGroup(A_Index , Group.ID)
10011005 }
1006+ this.EnableGroupView(GroupsEnabled)
10021007 }
10031008; =======================================================================================
10041009; Internal Functions: These functions are meant for internal use but can also
0 commit comments