Changeset View
Changeset View
Standalone View
Standalone View
libs/libkis/Node.cpp
Show First 20 Lines • Show All 315 Lines • ▼ Show 20 Line(s) | |||||
316 | { | 316 | { | ||
317 | if (!d->node) return 0; | 317 | if (!d->node) return 0; | ||
318 | return new Node(d->image, d->node->parent()); | 318 | return new Node(d->image, d->node->parent()); | ||
319 | } | 319 | } | ||
320 | 320 | | |||
321 | QString Node::type() const | 321 | QString Node::type() const | ||
322 | { | 322 | { | ||
323 | if (!d->node) return QString(); | 323 | if (!d->node) return QString(); | ||
324 | return QString(); | | |||
325 | if (qobject_cast<const KisPaintLayer*>(d->node)) { | 324 | if (qobject_cast<const KisPaintLayer*>(d->node)) { | ||
326 | return "paintlayer"; | 325 | return "paintlayer"; | ||
327 | } | 326 | } | ||
328 | else if (qobject_cast<const KisGroupLayer*>(d->node)) { | 327 | else if (qobject_cast<const KisGroupLayer*>(d->node)) { | ||
329 | return "grouplayer"; | 328 | return "grouplayer"; | ||
330 | } | 329 | } | ||
331 | if (qobject_cast<const KisFileLayer*>(d->node)) { | 330 | if (qobject_cast<const KisFileLayer*>(d->node)) { | ||
332 | return "filelayer"; | 331 | return "filelayer"; | ||
Show All 20 Lines | 351 | if (qobject_cast<const KisTransformMask*>(d->node)) { | |||
353 | return "transformmask"; | 352 | return "transformmask"; | ||
354 | } | 353 | } | ||
355 | if (qobject_cast<const KisSelectionMask*>(d->node)) { | 354 | if (qobject_cast<const KisSelectionMask*>(d->node)) { | ||
356 | return "selectionmask"; | 355 | return "selectionmask"; | ||
357 | } | 356 | } | ||
358 | if (qobject_cast<const KisColorizeMask*>(d->node)) { | 357 | if (qobject_cast<const KisColorizeMask*>(d->node)) { | ||
359 | return "colorizemask"; | 358 | return "colorizemask"; | ||
360 | } | 359 | } | ||
360 | return QString(); | ||||
361 | } | 361 | } | ||
362 | 362 | | |||
363 | bool Node::visible() const | 363 | bool Node::visible() const | ||
364 | { | 364 | { | ||
365 | if (!d->node) return false; | 365 | if (!d->node) return false; | ||
366 | return d->node->visible();; | 366 | return d->node->visible();; | ||
367 | } | 367 | } | ||
368 | 368 | | |||
▲ Show 20 Lines • Show All 200 Lines • Show Last 20 Lines |