1 /* |
1 /* |
2 * Copyright (c) 2002 Nokia Corporation and/or its subsidiary(-ies). |
2 * Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies). |
3 * All rights reserved. |
3 * All rights reserved. |
4 * This component and the accompanying materials are made available |
4 * This component and the accompanying materials are made available |
5 * under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members |
5 * under the terms of "Eclipse Public License v1.0" |
6 * which accompanies this distribution, and is available |
6 * which accompanies this distribution, and is available |
7 * at the URL "http://www.symbianfoundation.org/legal/licencesv10.html". |
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
8 * |
8 * |
9 * Initial Contributors: |
9 * Initial Contributors: |
10 * Nokia Corporation - initial contribution. |
10 * Nokia Corporation - initial contribution. |
11 * |
11 * |
12 * Contributors: |
12 * Contributors: |
260 * |
260 * |
261 * @since 5.0 |
261 * @since 5.0 |
262 * @param aCaption On return, this should be set to the caption of the target control. |
262 * @param aCaption On return, this should be set to the caption of the target control. |
263 */ |
263 */ |
264 void GetCaptionForFep(TDes& aCaption) const; |
264 void GetCaptionForFep(TDes& aCaption) const; |
265 |
265 |
|
266 /** |
|
267 * Calculates and returns setting item content rect. |
|
268 * |
|
269 * @param aScrollBarUsed @c ETrue if the setting page content should have |
|
270 * scrollbar, @c EFalse otherwise. |
|
271 * |
|
272 * @internal |
|
273 * @since 5.2 |
|
274 * @return Setting item content rectangle. |
|
275 */ |
|
276 TRect SettingItemContentRect( TBool aScrollBarUsed ); |
|
277 |
|
278 /** |
|
279 * Is the setting page drawing the background itself or not (= "transparency") |
|
280 */ |
|
281 TBool IsBackgroundDrawingEnabled() const; |
|
282 |
|
283 /** |
|
284 * Access method to the Command button array |
|
285 * |
|
286 * Must be called after full construction, or null reference will be returned. |
|
287 * |
|
288 * @return CEikButtonGroupContainer* a pointer to the cba owned by the setting page |
|
289 */ |
|
290 IMPORT_C CEikButtonGroupContainer* Cba() const ; |
|
291 |
266 protected: |
292 protected: |
267 |
293 |
268 /** |
294 /** |
269 * From CCoeControl |
295 * From CCoeControl |
270 * This routine is called as part of the set-up of the control. It is the place to put |
296 * This routine is called as part of the set-up of the control. It is the place to put |
417 * @return EFalse only if the CActiveSheduler level is not running |
443 * @return EFalse only if the CActiveSheduler level is not running |
418 */ |
444 */ |
419 IMPORT_C TBool Waiting(); |
445 IMPORT_C TBool Waiting(); |
420 |
446 |
421 /** |
447 /** |
422 * Access method to the Command button array |
|
423 * |
|
424 * Must be called after full construction, or null reference will be returned. |
|
425 * |
|
426 * @return CEikButtonGroupContainer* a pointer to the cba owned by the setting page |
|
427 */ |
|
428 IMPORT_C CEikButtonGroupContainer* Cba() const ; |
|
429 |
|
430 /** |
|
431 * This is used to access the default resource id for the cba - the one used when |
448 * This is used to access the default resource id for the cba - the one used when |
432 * data is valid. |
449 * data is valid. |
433 * |
450 * |
434 * @return TInt the default resource Id |
451 * @return TInt the default resource Id |
435 */ |
452 */ |
510 * This is called when the data changes. |
527 * This is called when the data changes. |
511 * |
528 * |
512 */ |
529 */ |
513 IMPORT_C virtual void CheckAndSetDataValidity(); |
530 IMPORT_C virtual void CheckAndSetDataValidity(); |
514 |
531 |
515 /** |
532 /** |
516 * Method to be called by CAknSettingPage descendents when they have laid themselves out. |
533 * Sets the outer and inner rectangle for the frame graphics that is drawn |
517 * This tells the base class how big the layout spec rectangle hosting the editor is. |
534 * around the setting item. |
518 * The second rectangle is the size of the area that the base class does not have to |
535 * |
519 * draw to for skins. Usually, this is the area actually inhabited by the editor control. |
536 * @param aOuterRect Frame outer rectangle. |
520 * |
537 * @param aInnerRect Frame inner rectangle. |
521 * Coordinates are to be given in pixels relative to the main_pane. |
538 * |
522 * |
539 * @since 5.2 |
523 * @param aFrameRect Layout rectangle in which to host the editor. |
540 */ |
524 * @param aRealEditorRect Layout rectangle actually occupied by the editor control |
541 void SetEditedItemFrameRects( const TRect& aOuterRect, |
525 * |
542 const TRect& aInnerRect ); |
526 * @since 2.0 |
543 |
527 */ |
544 /** |
528 void SetEditedItemLayoutRect( const TRect& aFrameRect, const TRect& aRealEditorRect); |
545 * Sets the skin item ID for the frame graphics that is drawn |
529 |
546 * around the setting item. |
530 /** |
547 * |
531 * Method to cause this class to construct a control context or type and IID, selected according to |
548 * @param aFrameIID Skin item ID of the frame graphics. |
532 * the value of enumeration TEditedItemSkinClass, set its coordinate system |
549 * @param aFrameCenterIID Skin item ID of the center piece of the frame |
533 * |
550 * graphics |
534 * This must be called after a call to SetEditedItemLayoutRect has been made on CAknSettingPage. |
551 * |
535 * This is becasue this routine must set the control context's origin to the top left of the value |
552 * @since 5.2 |
536 * given to SetEditedItemLayoutRect. Since SetEditeItemLayoutRect is to be called in a SizeChanged |
553 */ |
537 * method, this means that the this should be called after the SizeChanged in the child class. |
554 void SetEditedItemFrameIID( const TAknsItemID& aFrameIID, |
538 |
555 const TAknsItemID& aFrameCenterIID ); |
539 * @param aClass enumeration specifying which class of editor (according to LAF spec) is being |
556 |
540 * constructed. |
557 /** |
541 * @param aParentAbsolute ETrue if there is an intervening Window between CAknSettingPage's window |
558 * Sets the rectangle for the editing state indicators. |
542 * and any control that is to draw skin items with this component. |
559 * Should only be called by setting pages that have an editor which |
543 * |
560 * displays the editor indicators as the editor control. |
544 * since 2.0 |
561 * |
545 * |
562 * @param aRect Editor indicator rectangle. |
546 */ |
563 * |
547 void CreateEditedItemControlContextL( TEditedItemSkinClass aSkinClass, TBool aParentAbsolute); |
564 * @since 5.2 |
|
565 */ |
|
566 void SetEditorIndicatorRect( const TRect& aRect ); |
548 |
567 |
549 /** |
568 /** |
550 * Indicates whether skin system will be able to draw the editor frame and background |
569 * Indicates whether skin system will be able to draw the editor frame and background |
551 * |
570 * |
552 * @return TBool ETrue iff the drawing of the edited item frame is going to be handled by |
571 * @return TBool ETrue iff the drawing of the edited item frame is going to be handled by |
561 * @return A valid control context for frame drawing for a hosted editor or NULL |
580 * @return A valid control context for frame drawing for a hosted editor or NULL |
562 * @since 2.0 |
581 * @since 2.0 |
563 */ |
582 */ |
564 CAknsFrameBackgroundControlContext* EditedItemControlContext() const; |
583 CAknsFrameBackgroundControlContext* EditedItemControlContext() const; |
565 |
584 |
|
585 /** |
|
586 * Performs base construction and takes possible flags into account. |
|
587 * |
|
588 * @param aFlags Construction flags |
|
589 * |
|
590 * @since 5.2 |
|
591 */ |
|
592 void BaseConstructL( TUint aFlags ); |
|
593 |
|
594 /** |
|
595 * Stop current (additional) level on the active scheduler. |
|
596 */ |
|
597 void StopActiveScheduler(); |
566 |
598 |
567 protected: |
599 protected: |
568 /** |
600 /** |
569 * From MEikMenuObserver |
601 * From MEikMenuObserver |
570 * Called when menu is cancelled. |
602 * Called when menu is cancelled. |
702 * Enables / disables transparency effect, i.e. does the setting page draw its own background or not. |
730 * Enables / disables transparency effect, i.e. does the setting page draw its own background or not. |
703 * @param aDrawBackground EFalse enables transparency |
731 * @param aDrawBackground EFalse enables transparency |
704 */ |
732 */ |
705 void SetDrawBackground(const TBool aDrawBackground); |
733 void SetDrawBackground(const TBool aDrawBackground); |
706 |
734 |
707 /** |
|
708 * Is the setting page drawing the background itself or not (= "transparency") |
|
709 */ |
|
710 TBool IsBackgroundDrawingEnabled() const; |
|
711 /** |
735 /** |
712 * Set the flag to indicate that if the function CAknSettingPage::StopActiveScheduler called or not |
736 * Set the flag to indicate that if the function CAknSettingPage::StopActiveScheduler called or not |
713 *@param aStopCalled ETrue means the StopActiveScheduler is called. |
737 *@param aStopCalled ETrue means the StopActiveScheduler is called. |
714 */ |
738 */ |
715 void SetStopActiveSchedulerFlag(const TBool aStopCalled ); |
739 void SetStopActiveSchedulerFlag(const TBool aStopCalled ); |