equal
deleted
inserted
replaced
1 /* Copyright (c) 2009 The Khronos Group Inc. |
1 /* Copyright (c) 2009-2010 The Khronos Group Inc. |
|
2 * Portions copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies) |
2 * |
3 * |
3 * Permission is hereby granted, free of charge, to any person obtaining a |
4 * Permission is hereby granted, free of charge, to any person obtaining a |
4 * copy of this software and/or associated documentation files (the |
5 * copy of this software and/or associated documentation files (the |
5 * "Materials"), to deal in the Materials without restriction, including |
6 * "Materials"), to deal in the Materials without restriction, including |
6 * without limitation the rights to use, copy, modify, merge, publish, |
7 * without limitation the rights to use, copy, modify, merge, publish, |
139 OWF_API_CALL WFC_ELEMENT* |
140 OWF_API_CALL WFC_ELEMENT* |
140 WFC_Element_Create(WFC_CONTEXT* context) |
141 WFC_Element_Create(WFC_CONTEXT* context) |
141 { |
142 { |
142 static WFCint nextElementHandle = FIRST_ELEMENT_HANDLE; |
143 static WFCint nextElementHandle = FIRST_ELEMENT_HANDLE; |
143 WFC_ELEMENT* element; |
144 WFC_ELEMENT* element; |
|
145 |
|
146 OWF_ASSERT(context); |
144 |
147 |
145 element = (WFC_ELEMENT*)OWF_Pool_GetObject(context->elementPool); |
148 element = (WFC_ELEMENT*)OWF_Pool_GetObject(context->elementPool); |
146 |
149 |
147 if (element) |
150 if (element) |
148 { |
151 { |
388 break; |
391 break; |
389 } |
392 } |
390 |
393 |
391 case WFC_ELEMENT_SOURCE_FLIP: |
394 case WFC_ELEMENT_SOURCE_FLIP: |
392 { |
395 { |
393 WFCboolean flip = (WFCboolean) value; |
396 result = WFC_ERROR_NONE; |
394 |
|
395 result = BOOLEAN_TO_ERROR((WFC_TRUE == flip || |
|
396 WFC_FALSE == flip)); |
|
397 break; |
397 break; |
398 } |
398 } |
399 |
399 |
400 case WFC_ELEMENT_TRANSPARENCY_TYPES: |
400 case WFC_ELEMENT_TRANSPARENCY_TYPES: |
401 { |
401 { |