BrawlCrate v0.41
Wii File Editor
Loading...
Searching...
No Matches
Public Member Functions | Static Protected Member Functions | Properties | List of all members
BrawlCrate.NodeWrappers.TPLWrapper Class Reference
Inheritance diagram for BrawlCrate.NodeWrappers.TPLWrapper:
BrawlCrate.NodeWrappers.GenericWrapper BrawlCrate.NodeWrappers.BaseWrapper BrawlCrate.NodeWrappers.MultiSelectableWrapper

Public Member Functions

 TPLWrapper ()
 
void ImportTexture ()
 
- Public Member Functions inherited from BrawlCrate.NodeWrappers.GenericWrapper
 GenericWrapper (IWin32Window owner)
 
 GenericWrapper ()
 
virtual void Sort ()
 
void MoveUp ()
 
virtual void MoveUp (bool select)
 
void MoveDown ()
 
virtual void MoveDown (bool select)
 
void DeleteSelected ()
 
void ExportSelected ()
 
virtual string Export ()
 
virtual void OnExport (string outPath)
 
virtual void Replace ()
 
virtual void OnReplace (string inStream)
 
void Restore ()
 
virtual void Delete ()
 
void Rename ()
 
virtual ResourceNode Duplicate ()
 
virtual ResourceNode Duplicate (bool changeName)
 
- Public Member Functions inherited from BrawlCrate.NodeWrappers.BaseWrapper
void Link (ResourceNode res)
 
void Unlink ()
 

Static Protected Member Functions

static void NewEntryAction (object sender, EventArgs e)
 
- Static Protected Member Functions inherited from BrawlCrate.NodeWrappers.GenericWrapper
static void MoveUpAction (object sender, EventArgs e)
 
static void MoveDownAction (object sender, EventArgs e)
 
static void ExportAction (object sender, EventArgs e)
 
static void ExportSelectedAction (object sender, EventArgs e)
 
static void DeleteSelectedAction (object sender, EventArgs e)
 
static void DuplicateAction (object sender, EventArgs e)
 
static void ReplaceAction (object sender, EventArgs e)
 
static void RestoreAction (object sender, EventArgs e)
 
static void DeleteAction (object sender, EventArgs e)
 
static void RenameAction (object sender, EventArgs e)
 
static void SortAction (object sender, EventArgs e)
 
- Static Protected Member Functions inherited from BrawlCrate.NodeWrappers.BaseWrapper
static T GetInstance< T > ()
 
static IEnumerable< T > GetInstances< T > ()
 

Properties

override string ExportFilter [get]
 
- Properties inherited from BrawlCrate.NodeWrappers.GenericWrapper
virtual ContextMenuStrip MultiSelectMenuStrip [get]
 
virtual string DefaultName [get]
 
virtual string ExportFilter [get]
 
virtual string ImportFilter [get]
 
virtual string ReplaceFilter [get]
 
- Properties inherited from BrawlCrate.NodeWrappers.BaseWrapper
ResourceNode Resource [get]
 
virtual ? Color DefaultBackColor [get]
 
virtual ? Color DefaultForeColor [get]
 
- Properties inherited from BrawlCrate.NodeWrappers.MultiSelectableWrapper
ContextMenuStrip MultiSelectMenuStrip [get]
 

Additional Inherited Members

- Static Public Member Functions inherited from BrawlCrate.NodeWrappers.BaseWrapper
static BaseWrapper[] GetAllNodes (BaseWrapper root)
 
static BaseWrapper Wrap (ResourceNode node)
 
static BaseWrapper Wrap (IWin32Window owner, ResourceNode node)
 
- Static Public Attributes inherited from BrawlCrate.NodeWrappers.BaseWrapper
static IWin32Window _owner
 
- Protected Member Functions inherited from BrawlCrate.NodeWrappers.BaseWrapper
 BaseWrapper ()
 
- Protected Attributes inherited from BrawlCrate.NodeWrappers.BaseWrapper
bool _discovered
 
ResourceNode _resource
 
- Static Protected Attributes inherited from BrawlCrate.NodeWrappers.BaseWrapper
static readonly ContextMenuStrip _emptyMenu = new ContextMenuStrip()
 

Constructor & Destructor Documentation

◆ TPLWrapper()

BrawlCrate.NodeWrappers.TPLWrapper.TPLWrapper ( )
inline
84 {
85 ContextMenuStrip = _menu;
86 }

Member Function Documentation

◆ ImportTexture()

void BrawlCrate.NodeWrappers.TPLWrapper.ImportTexture ( )
inline
91 {
92 if (Program.OpenFile(FileFilters.Images, out string path))
93 {
94 if (path.EndsWith(".tplt", StringComparison.OrdinalIgnoreCase) || !path.Contains("."))
95 {
96 TPLTextureNode t = new TPLTextureNode {Name = "Texture"};
98 t.Replace(path);
99
100 BaseWrapper w = FindResource(t, true);
101 w.EnsureVisible();
102 w.TreeView.SelectedNode = w;
103 }
104 else
105 {
107 {
108 dlg.ImageSource = path;
109 if (dlg.ShowDialog(MainForm.Instance, Resource as TPLNode) == DialogResult.OK)
110 {
111 BaseWrapper w = FindResource(dlg.TPLTextureNode, true);
112 w.EnsureVisible();
113 w.TreeView.SelectedNode = w;
114 }
115 }
116 }
117 }
118 }
ResourceNode Resource
Definition: BaseWrapper.cs:77
ResourceNode _resource
Definition: BaseWrapper.cs:76
BaseWrapper()
Definition: BaseWrapper.cs:79
Definition: MainForm.cs:34
static MainForm Instance
Definition: MainForm.cs:36
Definition: TextureConverterDialog.cs:24
DialogResult ShowDialog(IWin32Window owner, BRRESNode parent)
Definition: TextureConverterDialog.cs:164
TPLTextureNode TPLTextureNode
Definition: TextureConverterDialog.cs:89
Definition: FileFilters.cs:8
static string Images
Definition: FileFilters.cs:89
virtual void AddChild(ResourceNode child)
Definition: ResourceNode.cs:757
Definition: TPLNode.cs:16
void Replace(Bitmap bmp)
Definition: TPLNode.cs:312

◆ NewEntryAction()

static void BrawlCrate.NodeWrappers.TPLWrapper.NewEntryAction ( object  sender,
EventArgs  e 
)
inlinestaticprotected
55 {
56 GetInstance<TPLWrapper>().ImportTexture();
57 }

Property Documentation

◆ ExportFilter

override string BrawlCrate.NodeWrappers.TPLWrapper.ExportFilter
get

The documentation for this class was generated from the following file: