mirror of
https://github.com/scratchfoundation/scratch-flash.git
synced 2024-12-04 21:21:06 -05:00
Fixed shadow disappearing when a script runs while being dragged
This commit is contained in:
parent
ab25a08ef4
commit
0556bcfe0d
1 changed files with 12 additions and 3 deletions
|
@ -298,13 +298,22 @@ public class Block extends Sprite {
|
|||
}
|
||||
|
||||
public function showRunFeedback():void {
|
||||
if (!filters || (filters.length == 0)) {
|
||||
filters = runFeedbackFilters();
|
||||
if (filters.length > 0) {
|
||||
for each (var f:* in filters) {
|
||||
if (f is GlowFilter) return;
|
||||
}
|
||||
}
|
||||
filters = runFeedbackFilters().concat(filters || []);
|
||||
}
|
||||
|
||||
public function hideRunFeedback():void {
|
||||
if (filters && (filters.length > 0)) filters = [];
|
||||
if (filters && filters.length > 0) {
|
||||
var newFilters:Array = [];
|
||||
for each (var f:* in filters) {
|
||||
if (!(f is GlowFilter)) newFilters.push(f);
|
||||
}
|
||||
filters = newFilters;
|
||||
}
|
||||
}
|
||||
|
||||
private function runFeedbackFilters():Array {
|
||||
|
|
Loading…
Reference in a new issue