You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

33 lines
886 B

  1. // Amplify Shader Editor - Visual Shader Editing Tool
  2. // Copyright (c) Amplify Creations, Lda <info@amplify.pt>
  3. using System.Collections.Generic;
  4. using UnityEngine;
  5. namespace AmplifyShaderEditor
  6. {
  7. public sealed class PaletteWindow : PaletteParent
  8. {
  9. public PaletteWindow( AmplifyShaderEditorWindow parentWindow ) : base( parentWindow, 0, 0, 250, 0, string.Empty, MenuAnchor.TOP_RIGHT, MenuAutoSize.MATCH_VERTICAL )
  10. {
  11. m_searchFilterControl += "PALETTEWINDOW";
  12. m_initialSeparatorAmount = 4;
  13. SetMinimizedArea( -225, 0, 260, 0 );
  14. }
  15. public override void Draw( Rect parentPosition, Vector2 mousePosition, int mouseButtonId, bool hasKeyboadFocus )
  16. {
  17. if ( m_isMaximized )
  18. {
  19. base.Draw( parentPosition, mousePosition, mouseButtonId, hasKeyboadFocus );
  20. }
  21. else
  22. {
  23. InitDraw( parentPosition, mousePosition, mouseButtonId );
  24. }
  25. PostDraw();
  26. }
  27. }
  28. }