Skip to content

Feature fix 149 touch widget #150

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Sep 6, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 38 additions & 2 deletions Scripts/Widgets/TouchWidget.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ protected override string GetName()

#region Private Data
[Serializable]
private class TapEventMapping
public class TapEventMapping
{
public GameObject m_TapObject = null;
public bool m_TapOnObject = true;
Expand All @@ -50,7 +50,7 @@ private class TapEventMapping
};

[Serializable]
private class FullScreenDragEventMapping
public class FullScreenDragEventMapping
{
[Tooltip("If there is no drag layer object set, it uses FullScreen")]
public GameObject m_DragLayerObject = null;
Expand All @@ -67,6 +67,42 @@ private class FullScreenDragEventMapping
private List<FullScreenDragEventMapping> m_FullScreenDragMappings = new List<FullScreenDragEventMapping>();
#endregion

#region Public Members

/// <summary>
/// Gets or sets the tap mappings.
/// </summary>
/// <value>The tap mappings.</value>
public List<TapEventMapping> TapMappings
{
get
{
return m_TapMappings;
}
set
{
m_TapMappings = value;
}
}

/// <summary>
/// Gets or sets the full screen drag mappings.
/// </summary>
/// <value>The full screen drag mappings.</value>
public List<FullScreenDragEventMapping> FullScreenDragMappings
{
get
{
return m_FullScreenDragMappings;
}
set
{
m_FullScreenDragMappings = value;
}
}

#endregion

#region Event Handlers
private void OnEnable()
{
Expand Down