blob: 9e3cba5b11b495f0e578c445478b713729d87244 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
// Shave and a Haircut
// (c) 2019 Epic Games
// US Patent 6720962
global string $shaveCursorCtxCommonValues_fileVersion = "$Revision$";
//
// This is a common values script for all shaveCursorCtx-based tools.
//
global proc shaveCursorCtxCommonValues(string $toolName)
{
toolPropertySetCommon($toolName, "", "");
shaveCursorCtx_updateCommonPropertySheet();
toolPropertySelect shaveCursor;
}
global proc shaveCursorCtx_updateCommonPropertySheet()
{
string $parent = (`toolPropertyWindow -q -location` + "|shaveCursor");
if (`layout -q -exists $parent`)
{
setParent $parent;
string $ctx = `currentCtx`;
string $class = `contextInfo -q -c $ctx`;
string $ctxCmd = $class + "Ctx";
if (`floatSliderGrp -exists shaveCursorSize`)
{
float $size = eval($ctxCmd + " -q -brushSize " + $ctx);
floatSliderGrp -e -v $size shaveCursorSize;
}
if (`floatSliderGrp -exists shaveCursorStren`)
{
float $s = eval($ctxCmd + " -q -brushStren " + $ctx);
floatSliderGrp -e -v $s shaveCursorStren;
}
if (`checkBoxGrp -exists shaveCursorEnableFalloff`)
{
int $enable = eval($ctxCmd + " -q -enableFalloff " + $ctx);
checkBoxGrp -e -v1 $enable shaveCursorEnableFalloff;
}
}
}
|