15 #include <boost/bind.hpp>
42 m_changeManager(iManager),
161 for(std::vector<FWEventItem*>::const_iterator it =
m_items.begin();
176 std::ostringstream os;
177 os << (*it)->defaultDisplayProperties().color();
182 std::ostringstream os;
183 os << (*it)->layer();
188 std::ostringstream os;
189 os << static_cast<int>((*it)->defaultDisplayProperties().transparency());
194 (*it)->getConfig()->addTo(pbTmp);
213 if (keyValues == 0)
return;
215 for (FWConfiguration::KeyValues::const_iterator it = keyValues->begin();
216 it != keyValues->end();
224 const std::string& moduleLabel = (*keyValues)[1].second.value();
225 const std::string& productInstanceLabel = (*keyValues)[2].second.value();
227 const std::string& filterExpression = (*keyValues)[4].second.value();
228 const std::string& sColor = (*keyValues)[5].second.value();
229 const bool isVisible = (*keyValues)[6].second.value() ==
kTrue;
231 unsigned int colorIndex;
234 std::istringstream is(sColor);
245 std::istringstream is(sColor);
249 int transparency = 0;
254 transparency = strtol((*keyValues)[9].second.value().c_str(), 0, 10);
258 unsigned int layer = strtol((*keyValues)[7].
second.value().c_str(), 0, 10);
263 purpose = (*keyValues)[8].second.value();
271 if (purpose ==
"VerticesWithTracks")
273 purpose =
"Vertices";
281 TClass::GetClass(type.c_str()),
285 productInstanceLabel,
290 add(desc, proxyConfig );
339 if (item && item->
name() == iName)
FWModelChangeManager * m_changeManager
std::vector< std::pair< std::string, FWConfiguration > > KeyValues
const KeyValues * keyValues() const
void removeItem(const FWEventItem *)
const FWDisplayProperties & displayProperties() const
static const std::string kModuleLabel("moduleLabel")
void setEvent(const edm::EventBase *iEvent)
const std::string & name() const
boost::shared_ptr< FWItemAccessorFactory > m_accessorFactory
void setFrom(const FWConfiguration &)
FWColorManager * colorManager() const
static const std::string kTrue("t")
static Color_t getDefaultStartColorIndex()
unsigned int version() const
Color_t oldColorToIndex(Color_t, int version) const
static const std::string kType("type")
void setContext(fireworks::Context *)
const TClass * type() const
bool colorHasIndex(Color_t) const
static const std::string kColor("color")
static const std::string kProductInstanceLabel("productInstanceLabel")
U second(std::pair< T, U > const &p)
static const std::string kFilterExpression("filterExpression")
static const std::string kProcessName("processName")
static const std::string kFalse("f")
void setDisplayProperties(const FWDisplayProperties &)
sigc::signal< void, FWEventItem * > newItem_
const FWEventItem * find(const std::string &iName) const
static const std::string kLayer("layer")
FWConfiguration & addKeyValue(const std::string &, const FWConfiguration &)
const edm::EventBase * m_event
const_iterator begin() const
NOTE: iterator is allowed to return a null object for items that have been removed.
static const std::string kTransparency("transparency")
void newEvent(const edm::EventBase *iEvent)
const FWEventItem * add(const FWPhysicsObjectDesc &iItem, const FWConfiguration *pbConf=0)
static const std::string kIsVisible("isVisible")
static const std::string kPurpose("purpose")
virtual ~FWEventItemsManager()
fireworks::Context * m_context
const FWConfiguration * valueForKey(const std::string &iKey) const
std::vector< FWEventItem * > m_items
void addTo(FWConfiguration &) const
std::vector< FWEventItem * >::const_iterator const_iterator
sigc::signal< void > goingToClearItems_
FWEventItemsManager(FWModelChangeManager *)
const_iterator end() const