Changeset 266 for trunk/src/object.cc


Ignore:
Timestamp:
06/19/14 03:49:49 (11 years ago)
Author:
epyon
Message:
  • decoupling - uid_store independent of nv::object
  • decoupling - nv::object no longer linked with lua in any way
  • decoupling - gui::element related object methods moved to element
  • uid_store can operate on void* or specialized base class
  • root class no longer carries uid store nor lua state (will be removed later)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/object.cc

    r265 r266  
    88
    99#include <algorithm>
    10 #include "nv/types.hh"
    11 #include "nv/lua/lua_state.hh"
    12 #include "nv/uid.hh"
    1310
    1411using namespace nv;
     
    1815        , m_name()
    1916        , m_uid(0)
    20         , m_lua_index(lua::ref::none)
    21         , m_lua_proto_index(lua::ref::none)
    2217        , m_parent( nullptr )
    2318        , m_children()
     
    124119}
    125120
    126 bool object::move_to_top( object* child )
    127 {
    128         list::iterator it = std::find( m_children.begin(), m_children.end(), child );
    129         if ( it != m_children.end() )
    130         {
    131                 m_children.erase( it );
    132                 m_children.push_back( child );
    133                 return true;
    134         }       
    135         return false;
    136 }
    137 
    138 bool object::move_to_bottom( object* child )
    139 {
    140         list::iterator it = std::find( m_children.begin(), m_children.end(), child );
    141         if ( it != m_children.end() )
    142         {
    143                 m_children.erase( it );
    144                 m_children.push_front( child );
    145                 return true;
    146         }       
    147         return false;
    148 }
    149121
    150122// void object::register_type( type_database* db )
Note: See TracChangeset for help on using the changeset viewer.