SWwiseReconcile.h 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. /*******************************************************************************
  2. The content of this file includes portions of the proprietary AUDIOKINETIC Wwise
  3. Technology released in source code form as part of the game integration package.
  4. The content of this file may not be used without valid licenses to the
  5. AUDIOKINETIC Wwise Technology.
  6. Note that the use of the game engine is subject to the Unreal(R) Engine End User
  7. License Agreement at https://www.unrealengine.com/en-US/eula/unreal
  8. License Usage
  9. Licensees holding valid licenses to the AUDIOKINETIC Wwise Technology may use
  10. this file in accordance with the end user license agreement provided with the
  11. software or, alternatively, in accordance with the terms contained
  12. in a written agreement between you and Audiokinetic Inc.
  13. Copyright (c) 2023 Audiokinetic Inc.
  14. *******************************************************************************/
  15. #pragma once
  16. #include "Wwise/WwiseReconcile.h"
  17. #include "IWwiseReconcileColumn.h"
  18. #include "Widgets/SWindow.h"
  19. class SWwiseReconcileListView;
  20. class SWwiseReconcile : public SCompoundWidget
  21. {
  22. public:
  23. SLATE_BEGIN_ARGS(SWwiseReconcile)
  24. : _FocusSearchBoxWhenOpened(false)
  25. , _ShowTreeTitle(true)
  26. , _ShowSeparator(true)
  27. , _AllowContextMenu(true)
  28. {}
  29. /** Content displayed to the left of the search bar */
  30. SLATE_NAMED_SLOT(FArguments, SearchContent)
  31. /** If true, the search box will be focus the frame after construction */
  32. SLATE_ARGUMENT(bool, FocusSearchBoxWhenOpened)
  33. /** If true, The tree title will be displayed */
  34. SLATE_ARGUMENT(bool, ShowTreeTitle)
  35. /** If true, The tree search bar separator be displayed */
  36. SLATE_ARGUMENT(bool, ShowSeparator)
  37. /** If false, the context menu will be suppressed */
  38. SLATE_ARGUMENT(bool, AllowContextMenu)
  39. ///** The selection mode for the tree view */
  40. //SLATE_ARGUMENT(ESelectionMode::Type, SelectionMode)
  41. SLATE_END_ARGS()
  42. WWISERECONCILE_API void Construct(const FArguments& InArgs, const TArray< FWwiseReconcileItem >& ReconcileItems, TSharedRef<SWindow>& ReconcileWindow);
  43. WWISERECONCILE_API SWwiseReconcile();
  44. /** Get the columns to be displayed in this outliner */
  45. const TMap<FName, TSharedPtr<IWwiseReconcileColumn>>& GetColumns() const
  46. {
  47. return Columns;
  48. }
  49. private:
  50. FReply ReconcileAssets();
  51. FReply CloseWindow();
  52. void SetupColumns(SHeaderRow& HeaderRow);
  53. /** Generate a row in the tree view */
  54. TSharedRef<ITableRow> GenerateRow(TSharedPtr<FWwiseReconcileItem> Item, const TSharedRef<STableViewBase>& OwnerTable);
  55. /** The header row of the Reconcile view */
  56. TSharedPtr< SHeaderRow > HeaderRowWidget;
  57. /** Items to Reconcile */
  58. TArray< TSharedPtr<FWwiseReconcileItem> > ReconcileItems;
  59. TSharedPtr<SWwiseReconcileListView> ReconcileList;
  60. /** Map of columns that are shown on the Picker. */
  61. TMap<FName, TSharedPtr<IWwiseReconcileColumn>> Columns;
  62. TWeakPtr<SWindow> Window;
  63. };