Compare commits

..

11 Commits

Author SHA1 Message Date
oguzhankoral a6351659da Use insertion point for instances 2024-01-08 14:33:11 +03:00
oguzhankoral 80f62e6ee4 Fix transformation matrix 2024-01-08 12:17:48 +03:00
oguzhankoral b4761650b9 Calculate rotation of family instance 2023-12-08 02:15:56 +03:00
oguzhankoral 7921ab1f36 Add direct shape option to components back 2023-12-07 21:22:04 +03:00
oguzhankoral 3f793dc9db Exclude definitions from conversion escape
- Previously we were using definition mappings only for direct shape conversions but now they can live in instances
2023-12-07 21:19:02 +03:00
oguzhankoral 7b3f2e47bb Pass group selection info if only group selected 2023-12-07 16:09:12 +03:00
oguzhankoral 1a4e3b5a44 Implement family instance mapping 2023-12-07 16:03:02 +03:00
oguzhankoral ed0e1bf249 Set hard coded categories just once and source families when source set/updated 2023-12-07 16:02:37 +03:00
oguzhankoral 5e9566c1d6 Adjust available mapping methods according to selection 2023-12-07 16:01:51 +03:00
oguzhankoral 24ec910735 Filter family types for 'Family Instance' 2023-12-07 16:01:13 +03:00
oguzhankoral e4c53f536d Implement New Revit Family option 2023-12-05 23:05:38 +03:00
6 changed files with 7 additions and 64 deletions
@@ -1,27 +0,0 @@
# frozen_string_literal: true
require_relative 'command'
require_relative '../states/initial_state'
require_relative '../ui/vue_view'
require_relative '../actions/initialize_speckle'
require_relative '../observers/factory'
module SpeckleConnector
module Commands
# Command to reset Speckle UI window location onto center of SketchUp window.
class ResetWindowLocation < Command
private
def _run
app = self.app
vue_view = app.ui_controller.user_interfaces[Ui::SPECKLE_UI_ID]
if vue_view
vue_view.dialog.reset_dialog_location
else
puts "Speckle UI didn't initialized!"
end
end
end
end
end
@@ -3,7 +3,6 @@
require_relative 'menu_command_handler'
require_relative 'action_command'
require_relative 'initialize_speckle'
require_relative 'reset_window_location'
require_relative '../actions/one_click_send'
module SpeckleConnector
@@ -11,7 +10,6 @@ module SpeckleConnector
# Speckle menu commands that adds them to Sketchup menu and toolbar.
class SpeckleMenuCommands
CMD_INITIALIZE_SPECKLE = :initialize_speckle
CMD_RESET_WINDOW_LOCATION_SPECKLE = :reset_window_location_speckle
CMD_SEND_TO_SPECKLE = :send_to_speckle
CMD_RECEIVE_FROM_SPECKLE = :receive_from_speckle
@@ -28,9 +26,6 @@ module SpeckleConnector
commands.add_to_menu!(CMD_INITIALIZE_SPECKLE, speckle_menu)
commands.add_to_toolbar!(CMD_INITIALIZE_SPECKLE, speckle_toolbar)
commands[CMD_RESET_WINDOW_LOCATION_SPECKLE] = reset_window_location_command(app)
commands.add_to_menu!(CMD_RESET_WINDOW_LOCATION_SPECKLE, speckle_menu)
# commands[CMD_SEND_TO_SPECKLE] = send_command(app)
# commands.add_to_menu!(CMD_SEND_TO_SPECKLE, speckle_menu)
# commands.add_to_toolbar!(CMD_SEND_TO_SPECKLE, speckle_toolbar)
@@ -47,17 +42,6 @@ module SpeckleConnector
cmd
end
def self.reset_window_location_command(app)
cmd = MenuCommandHandler.sketchup_command(
ResetWindowLocation.new(app), 'Reset Window Location'
)
cmd.tooltip = 'Bring Speckle window onto center of SketchUp window'
cmd.status_bar_text = 'Bring Speckle window onto center of SketchUp window'
cmd.small_icon = '../../img/s2logo.png'
cmd.large_icon = '../../img/s2logo.png'
cmd
end
def self.send_command(app)
cmd = MenuCommandHandler.sketchup_command(
ActionCommand.new(app, Actions::OneClickSend), 'Send to Speckle'
-4
View File
@@ -57,10 +57,6 @@ module SpeckleConnector
html_dialog.execute_script(data)
end
def reset_dialog_location
html_dialog.center
end
private
# @return [UI::HtmlDialog] the Sketchup interface to dialog
+1 -4
View File
@@ -101,8 +101,7 @@
</v-container>
<create-stream-dialog
v-if="accounts().length !== 0"
:is-f-e2-terms="preferences && preferences.user && preferences.user.fe2"
:is-f-e2="activeAccount().serverInfo.frontend2"
:is-f-e2="preferences && preferences.user && preferences.user.fe2"
:account-id="activeAccount().userInfo.id"
:server-url="activeAccount().serverInfo.url"
/>
@@ -242,8 +241,6 @@ export default {
switchAccount(account) {
this.$mixpanel.track('Connector Action', { name: 'Account Select' })
global.setSelectedAccount(account)
// Force pushes to reload page to create ApolloClient from scratch
location.reload()
},
requestRefresh() {
sketchup.exec({name: 'reload_accounts', data: {}})
+2 -5
View File
@@ -623,6 +623,8 @@ export default {
this.selectedLevel = this.levels[0].name
}
}
console.log(this.selectedFamily, "selectedFamily after")
console.log(this.selectedLevel, "selectedLevel after")
},
hideOptionalMappingInputs(){
this.categorySelectionActive = false
@@ -711,11 +713,6 @@ export default {
}
this.selectedMethod = this.lastSelectedEntity['definition']['schema']['method']
this.selectedCategory = this.lastSelectedEntity['definition']['schema']['category']
this.selectedFamily = this.lastSelectedEntity['definition']['schema']['family']
this.getFamiliesFromSelectedMethod()
this.getTypesFromSelectedFamily()
this.selectedFamilyType = this.lastSelectedEntity['definition']['schema']['family_type']
this.selectedLevel = this.lastSelectedEntity['definition']['schema']['level']
this.updateMappingInputs()
}
}
@@ -17,13 +17,13 @@
>
mdi-plus-circle
</v-icon>
{{ `Create New ${isFE2Terms ? 'Project': 'Stream'}` }}
{{ `Create New ${isFE2 ? 'Project': 'Stream'}` }}
</v-btn>
</template>
<v-card>
<v-card-title class="text-h5">
{{ `Create a New ${isFE2Terms ? 'Project' : 'Stream'}` }}
{{ `Create a New ${isFE2 ? 'Project' : 'Stream'}` }}
</v-card-title>
<v-container class="px-6" pb-0>
<!--
@@ -56,7 +56,7 @@
hide-details
dense
flat
:placeholder="`${isFE2Terms ? 'Project' : 'Stream'} Name (Optional)`"
:placeholder="`${isFE2 ? 'Project' : 'Stream'} Name (Optional)`"
/>
<v-text-field
v-model="description"
@@ -68,7 +68,7 @@
/>
<v-switch
v-model="privateStream"
:label="`Private ${isFE2Terms ? 'Project' : 'Stream'}`"
:label="`Private ${isFE2 ? 'Project' : 'Stream'}`"
></v-switch>
</v-container>
@@ -174,10 +174,6 @@ export default {
isFE2: {
type: Boolean,
default: false
},
isFE2Terms: {
type: Boolean,
default: false
}
},
data() {