Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
XDG Integration
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Silent mode is enabled
All outbound communications are blocked.
Learn more
.
Show more breadcrumbs
JennaHuntsman
XDG Integration
Commits
ae594765
Commit
ae594765
authored
8 years ago
by
andreykproductengine
Browse files
Options
Downloads
Patches
Plain Diff
MAINT-7225 Blocks list wasn't updating corretly for name based muting.
parent
16bf3611
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
indra/newview/llblocklist.cpp
+36
-17
36 additions, 17 deletions
indra/newview/llblocklist.cpp
with
36 additions
and
17 deletions
indra/newview/llblocklist.cpp
+
36
−
17
View file @
ae594765
...
@@ -130,7 +130,14 @@ BOOL LLBlockList::handleRightMouseDown(S32 x, S32 y, MASK mask)
...
@@ -130,7 +130,14 @@ BOOL LLBlockList::handleRightMouseDown(S32 x, S32 y, MASK mask)
void
LLBlockList
::
removeListItem
(
const
LLMute
*
mute
)
void
LLBlockList
::
removeListItem
(
const
LLMute
*
mute
)
{
{
removeItemByUUID
(
mute
->
mID
);
if
(
mute
->
mID
.
notNull
())
{
removeItemByUUID
(
mute
->
mID
);
}
else
{
removeItemByValue
(
mute
->
mName
);
}
}
}
void
LLBlockList
::
hideListItem
(
LLBlockedListItem
*
item
,
bool
show
)
void
LLBlockList
::
hideListItem
(
LLBlockedListItem
*
item
,
bool
show
)
...
@@ -178,7 +185,14 @@ void LLBlockList::addNewItem(const LLMute* mute)
...
@@ -178,7 +185,14 @@ void LLBlockList::addNewItem(const LLMute* mute)
{
{
item
->
highlightName
(
mNameFilter
);
item
->
highlightName
(
mNameFilter
);
}
}
addItem
(
item
,
item
->
getUUID
(),
ADD_BOTTOM
);
if
(
item
->
getUUID
().
notNull
())
{
addItem
(
item
,
item
->
getUUID
(),
ADD_BOTTOM
);
}
else
{
addItem
(
item
,
item
->
getName
(),
ADD_BOTTOM
);
}
}
}
void
LLBlockList
::
refresh
()
void
LLBlockList
::
refresh
()
...
@@ -186,7 +200,8 @@ void LLBlockList::refresh()
...
@@ -186,7 +200,8 @@ void LLBlockList::refresh()
bool
have_filter
=
!
mNameFilter
.
empty
();
bool
have_filter
=
!
mNameFilter
.
empty
();
// save selection to restore it after list rebuilt
// save selection to restore it after list rebuilt
LLUUID
selected
=
getSelectedUUID
(),
next_selected
;
LLSD
selected
=
getSelectedValue
();
LLSD
next_selected
;
if
(
mShouldAddAll
)
// creating list of blockers
if
(
mShouldAddAll
)
// creating list of blockers
{
{
...
@@ -204,14 +219,15 @@ void LLBlockList::refresh()
...
@@ -204,14 +219,15 @@ void LLBlockList::refresh()
}
}
else
if
(
mActionType
==
REMOVE
)
else
if
(
mActionType
==
REMOVE
)
{
{
if
(
selected
==
mute
.
mID
)
if
((
mute
.
mID
.
notNull
()
&&
selected
.
isUUID
()
&&
selected
.
asUUID
()
==
mute
.
mID
)
||
mute
.
mID
.
isNull
()
&&
selected
.
isString
()
&&
selected
.
asString
()
==
mute
.
mName
)
{
{
// we are going to remove currently selected item, so select next item and save the selection to restore it
// we are going to remove currently selected item, so select next item and save the selection to restore it
if
(
!
selectNextItemPair
(
false
,
true
))
if
(
!
selectNextItemPair
(
false
,
true
))
{
{
selectNextItemPair
(
true
,
true
);
selectNextItemPair
(
true
,
true
);
}
}
next_selected
=
getSelected
UUID
();
next_selected
=
getSelected
Value
();
}
}
removeListItem
(
&
mute
);
removeListItem
(
&
mute
);
}
}
...
@@ -237,15 +253,18 @@ void LLBlockList::refresh()
...
@@ -237,15 +253,18 @@ void LLBlockList::refresh()
}
}
mPrevNameFilter
=
mNameFilter
;
mPrevNameFilter
=
mNameFilter
;
if
(
getItemPair
(
selected
))
if
(
selected
.
isDefined
())
{
// restore previously selected item
selectItemPair
(
getItemPair
(
selected
),
true
);
}
else
if
(
getItemPair
(
next_selected
))
{
{
// previously selected item was removed, so select next item
if
(
getItemPair
(
selected
))
selectItemPair
(
getItemPair
(
next_selected
),
true
);
{
// restore previously selected item
selectItemPair
(
getItemPair
(
selected
),
true
);
}
else
if
(
next_selected
.
isDefined
()
&&
getItemPair
(
next_selected
))
{
// previously selected item was removed, so select next item
selectItemPair
(
getItemPair
(
next_selected
),
true
);
}
}
}
mMuteListSize
=
LLMuteList
::
getInstance
()
->
getMutes
().
size
();
mMuteListSize
=
LLMuteList
::
getInstance
()
->
getMutes
().
size
();
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment