Example #1
0
        private Layout CreateLayoutFromData(object data,
                                            Group group,
                                            DeclarativeTemplateBuildContext bc)
        {
            string title = DataNodeWrapper.GetAttribute(data, DataNodeWrapper.TITLE);
            if (title == DataNodeWrapper.POPUP)
            {
                string layoutTitle = DataNodeWrapper.GetAttribute(data, DataNodeWrapper.LAYOUTTITLE);

                group.PopupLayoutTitle = layoutTitle;
                return null;
            }

            Layout layout = bc.Ribbon.CreateLayout(group.Id + "-" + title, title);

            layout.SetDelayedInitData(new DelayedInitHandler(this.DelayInitLayout), data, bc);
            // Comment out the SetDelayedInitData() line and uncomment this one to disable
            // on-demand construction of layouts.
            // FillLayout(data, layout, bc);
            return layout;
        }
Example #2
0
 internal GroupPopupLayout(SPRibbon ribbon, string id, Group group)
     : base(ribbon, id, "Popup")
 {
     _group = group;
 }
Example #3
0
 internal GroupPopup(SPRibbon ribbon, string id, Group group)
     : base(ribbon, id, "", "")
 {
     _group = group;
 }
Example #4
0
 internal GroupPopupLayout CreateGroupPopupLayout(string id, Group group)
 {
     return new GroupPopupLayout(this, id, group);
 }
Example #5
0
 internal GroupPopup CreateGroupPopup(string id, Group group)
 {
     return new GroupPopup(this, id, group);
 }