Browse Source

mol-geo: removed Structure param

David Sehnal 6 years ago
parent
commit
958bbb79b4
2 changed files with 3 additions and 14 deletions
  1. 1 3
      src/mol-geo/geometry/geometry.ts
  2. 2 11
      src/mol-util/parameter.ts

+ 1 - 3
src/mol-geo/geometry/geometry.ts

@@ -15,8 +15,7 @@ import { LocationIterator } from '../util/location-iterator';
 import { ColorType } from './color-data';
 import { SizeType } from './size-data';
 import { Lines } from './lines/lines';
-import { paramDefaultValues, RangeParam, BooleanParam, SelectParam, ColorParam, StructureParam, ValueParam } from 'mol-util/parameter'
-import { Structure } from 'mol-model/structure';
+import { paramDefaultValues, RangeParam, BooleanParam, SelectParam, ColorParam, ValueParam } from 'mol-util/parameter'
 import { DirectVolume } from './direct-volume/direct-volume';
 import { Context } from 'mol-gl/webgl/context';
 
@@ -68,7 +67,6 @@ export namespace Geometry {
         quality: SelectParam<VisualQuality>('Quality', '', 'auto', VisualQualityOptions),
         colorTheme: SelectParam<ColorThemeName>('Color Theme', '', 'uniform', ColorThemeOptions),
         colorValue: ColorParam('Color Value', '', Color(0xCCCCCC)),
-        structure: StructureParam('Structure', '', Structure.Empty),
         webgl: ValueParam('WebGL Context', '', undefined as Context | undefined),
     }
     export const DefaultProps = paramDefaultValues(Params)

+ 2 - 11
src/mol-util/parameter.ts

@@ -4,8 +4,7 @@
  * @author Alexander Rose <alexander.rose@weirdbyte.de>
  */
 
-import { Color } from 'mol-util/color';
-import { Structure } from 'mol-model/structure';
+import { Color } from './color';
 
 export interface BaseParam<T> {
     label: string
@@ -81,15 +80,7 @@ export function NumberParam(label: string, description: string, defaultValue: nu
     return { type: 'number', label, description, defaultValue, min, max, step }
 }
 
-export interface StructureParam extends BaseParam<Structure> {
-    type: 'structure'
-}
-export function StructureParam(label: string, description: string, defaultValue: Structure): StructureParam {
-    return { type: 'structure', label, description, defaultValue }
-}
-
-export type Param = ValueParam<any> | SelectParam<any> | MultiSelectParam<any> | BooleanParam | RangeParam | TextParam | ColorParam | NumberParam | StructureParam
-
+export type Param = ValueParam<any> | SelectParam<any> | MultiSelectParam<any> | BooleanParam | RangeParam | TextParam | ColorParam | NumberParam
 export type Params = { [k: string]: Param }
 
 export function paramDefaultValues<T extends Params>(params: T) {