Popup.cxx (778b1054) Popup.cxx (550fbbbd)
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance

--- 112 unchanged lines hidden (view full) ---

121
122
123
124
125void Popup::CreateContainerAndControl (void)
126{
127 mpContainer.reset(new PopupContainer(mpParent));
128 mpContainer->SetAccessibleName(msAccessibleName);
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance

--- 112 unchanged lines hidden (view full) ---

121
122
123
124
125void Popup::CreateContainerAndControl (void)
126{
127 mpContainer.reset(new PopupContainer(mpParent));
128 mpContainer->SetAccessibleName(msAccessibleName);
129 if (maPopupModeEndCallback)
130 mpContainer->SetPopupModeEndHdl(LINK(this, Popup, PopupModeEndHandler));
129 mpContainer->SetPopupModeEndHdl(LINK(this, Popup, PopupModeEndHandler));
131 mpContainer->SetBorderStyle(mpContainer->GetBorderStyle() | WINDOW_BORDER_MENU);
130 mpContainer->SetBorderStyle(mpContainer->GetBorderStyle() | WINDOW_BORDER_MENU);
132
131
133 mpControl.reset(maControlCreator(mpContainer.get()));
134}
135
136
137
138
139IMPL_LINK(Popup, PopupModeEndHandler, void*, EMPTYARG)
140{
141 if (maPopupModeEndCallback)
142 maPopupModeEndCallback();
132 mpControl.reset(maControlCreator(mpContainer.get()));
133}
134
135
136
137
138IMPL_LINK(Popup, PopupModeEndHandler, void*, EMPTYARG)
139{
140 if (maPopupModeEndCallback)
141 maPopupModeEndCallback();
142
143 // Popup control is no longer needed and can be destroyed.
144 mpControl.reset();
145 mpContainer.reset();
146
143 return 0;
144}
145
146
147
148} } // end of namespace svx::sidebar
147 return 0;
148}
149
150
151
152} } // end of namespace svx::sidebar