Changes between Version 15 and Version 16 of EFLWebKitCodingStyle


Ignore:
Timestamp:
Aug 31, 2012, 3:01:41 AM (12 years ago)
Author:
gyuyoung.kim@samsung.com
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • EFLWebKitCodingStyle

    v15 v16  
    33 * EFL port should adhere to the WebKit Coding Style basically.(http://www.webkit.org/coding/coding-style.html)
    44 * Do not use '''abbreviation''' except for public APIs
    5  * Do not use '''Eina_Bool''' type except for public APIs
     5 * Do not use '''Eina_Bool''' type except for public APIs and callback function for EFL event handler.
    66 * Place '*' operator to data type
    77 * Use C++ casting for type casting. For example, '''static_cast<...>, const_cast<...>, reinterpret_cast<...>'''
     
    4040}}}
    4141
    42 == Do not use Eina_Bool type except for public APIs ==
     42== Do not use Eina_Bool type except for public APIs and callback function for EFL event handler ==
    4343=== Public APIs ===
    4444{{{
     
    6868}}}
    6969
     70=== Callback function for EFL event handler ===
     71{{{
     72#!cpp
     73
     74Eina_Bool GamepadDeviceEfl::readCallback(void* userData, Ecore_Fd_Handler* fdHandler)
     75{
     76    GamepadDeviceEfl* gamepadDevice = static_cast<GamepadDeviceEfl*>(userData);
     77    ...
     78    return ECORE_CALLBACK_RENEW;
     79}
     80
     81GamepadDeviceEfl::GamepadDeviceEfl(const String& deviceFile)
     82    : GamepadDeviceLinux(deviceFile)
     83    , m_fdHandler(0)
     84    , m_deviceFile(deviceFile)
     85{
     86    m_fdHandler = ecore_main_fd_handler_add(m_fileDescriptor, ECORE_FD_READ, readCallback, this, 0, 0);
     87   ...
     88}
     89}}}
     90
    7091== Use "void" for empty parameter of public APIs ==
    7192=== Right ===