Exemple #1
0
	InkStyle& Style::subskin(WidgetState state)
	{
		for(SubSkin& skin : reverse_adapt(mSubskins))
			if((state & skin.mState) == skin.mState)
				return skin.mSkin;
		return mSkin;
	}
Exemple #2
0
	InkStyle& Style::copy(WidgetState state, InkStyle& original, bool inherit)
	{
		for(SubSkin& skin : reverse_adapt(mSubskins))
			if(state == skin.mState)
			{
				skin.mSkin.copy(original, inherit);
				return skin.mSkin;
			}

		mSubskins.emplace_back(state);
		mSubskins.back().mSkin.copy(original, inherit);
		return mSubskins.back().mSkin;
	}
Exemple #3
0
	Frame* Layer::pinpoint(float x, float y, bool opaque)
	{
		Frame* result = nullptr;
		for(Layer* layer : reverse_adapt(d_layers))
			if(layer->visible() && layer->frameType() != LAYER3D)
			{
				result = layer->pinpoint(x, y, opaque);
				if(result)
					return result;
			}

		result = Stripe::pinpoint(x, y, opaque);
		return result;
	}