Back to index

unity  6.0.0
Public Member Functions
unity::dash::FilterFactory Class Reference

#include <FilterFactory.h>

List of all members.

Public Member Functions

FilterExpanderLabelWidgetForFilter (Filter::Ptr const &filter)

Detailed Description

Definition at line 35 of file FilterFactory.h.


Member Function Documentation

Definition at line 47 of file FilterFactory.cpp.

{
  std::string filter_type(filter->renderer_name);
  LOG_DEBUG(logger) << "building filter of type, " << filter_type;

  FilterExpanderLabel* widget = nullptr;
  if (filter_type == renderer_type_check_options)
  {
    widget = new FilterGenre(2, NUX_TRACKER_LOCATION);
  }
  else if (filter_type == renderer_type_check_options_compact)
  {
    widget = new FilterGenre(3, NUX_TRACKER_LOCATION);
  }
  else if (filter_type == renderer_type_ratings)
  {
    widget = new FilterRatingsWidget(NUX_TRACKER_LOCATION);
  }
  else if (filter_type == renderer_type_multirange)
  {
    widget = new FilterMultiRange(NUX_TRACKER_LOCATION);
  }
  else if (filter_type == renderer_type_radio_options)
  {
    widget = new FilterGenre(2, NUX_TRACKER_LOCATION);
  }
  else
  {
    LOG_WARNING(logger) << "Do not understand filter of type \""
                        << filter_type
                        << "\"";
  }

  if (widget)
    widget->SetFilter(filter);

  return widget;
}

Here is the call graph for this function:

Here is the caller graph for this function:


The documentation for this class was generated from the following files: