コード例 #1
0
    void SetQuickBarShortcut(SceneObject sceneObject, int index, Texture texture)
    {
        OnQuickBarAdd?.Invoke(sceneObject, index);

        if (index >= shortcutsImgs.Length)
        {
            return;
        }

        shortcutsImgs[index].SetTexture(texture);
    }
コード例 #2
0
ファイル: QuickBarView.cs プロジェクト: eyesnareinc/explorer
    private void SetQuickBarShortcut(CatalogItem catalogItem, int index, Texture texture)
    {
        OnQuickBarAdd?.Invoke(catalogItem, index);

        if (index >= shortcutsImgs.Length)
        {
            return;
        }

        if (shortcutsImgs[index] != null && texture != null)
        {
            shortcutsImgs[index].SetTexture(texture);
        }
    }