Commit 1f17c9b3 authored by Jocelyn Turcotte's avatar Jocelyn Turcotte Committed by The Qt Project
Browse files

Refactor the way callbacks are stored


With the upcoming addition of a new type of callback result, this
patch allows storing multiple callback types in the same QHash instead
or requiring a different hash table just to please the type system.

This does so by managing the ref-counted callback pointers directly
instead of relying on a templated QExplicitlySharedDataPointer that
requires a different type for each different callback pointer type.

The ref-counting, construction and destruction is managed through
a run-time type enum.

Change-Id: I90ab2e1efc0c9703fc5b6ef57b38204ac8eea828
Reviewed-by: default avatarSimon Hausmann <simon.hausmann@digia.com>
Showing with 120 additions and 22 deletions
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment